problem with 'Vector / Wind Barb Colored by Speed'

Errors and unexpected results
Post Reply
User avatar
hproe
Posts: 504
Joined: Sat Nov 27, 2010 3:46 pm

problem with 'Vector / Wind Barb Colored by Speed'

Post by hproe »

Hi-

I have discovered the display type 'Vector / Wind Barb Colored by Speed' in recent nighlties (not sure how long it is there). It works as expected with netCDF files with ASCAT winds when using my derived formula 'Flow Vectors ...'. However, when using my derived formula 'Ocean Flow Vectors .., which is the one that goes with ASCAT, a solid colour is applied to the vectors or wind barbs. The only difference between the two formulas is that the Ocean one inverts the direction, like

Code: Select all

DerivedGridFactory.createFlowVectors (D1,D2+180)

A sample file 'ascat_20160410_161200_metopa_49170_eps_o_coa_2401_ovw.l2.nc' is uploaded to the SSEC server.

HP
User avatar
bobc
Posts: 988
Joined: Mon Nov 15, 2010 5:57 pm

Re: problem with 'Vector / Wind Barb Colored by Speed'

Post by bobc »

Hi HP -

Thanks for the bug report. I'm replicating the problem and wrote it up as Inquiry 2327. I found that a workaround is that after the display is created you can go to File>Reload Data in the Layer Controls. In some brief testing, I also saw that as items in the Layer Controls are changed, the barbs/vectors can lose their color as well. If you see this happen, you would need to reload the display again. If you give this a try, please let me know if it helps.

The updated display types and controls for vectors/wind barbs has been in the McIDAS-V nightly since near the end of February, and they are a result of VisAD changes as well as some work done by Unidata IDV. If you work with these displays and controls and find any other bugs, have enhancement ideas, or any questions, please let me know.

Thanks again -
Bob Carp
User avatar
bobc
Posts: 988
Joined: Mon Nov 15, 2010 5:57 pm

Re: problem with 'Vector / Wind Barb Colored by Speed'

Post by bobc »

Hi HP -

We updated the IDV version in the McIDAS-V nightly this afternoon. This new nightly is available online. I just gave this a try with the new nightly, and the Oceanographic Wind Barbs/Vectors colored by speed now display colored correctly right away without having to reload the display. If you give a new nightly a try and still see problems with the coloring, please let me know. Note that there can be some issues with the vectors/barbs displaying too large, but with manually adjusting the size in the Layer Controls with your zoom level in the Main Display you should be able to get a good display.

Thanks -
Bob
User avatar
hproe
Posts: 504
Joined: Sat Nov 27, 2010 3:46 pm

Re: problem with 'Vector / Wind Barb Colored by Speed'

Post by hproe »

Hi Bob -

The updated IDV module does a good job, indeed. Vectors and barbs display now speed-coloured and colours stay put (so far). Idem for RapidScat data. Looks like also the autosize feature for the vectors/barbs and manual scaling are working much better now (was a long standing problem).

I wonder whether the default colour scale could be changed and how.

many thanks for the quick turn-around, HP
User avatar
bobc
Posts: 988
Joined: Mon Nov 15, 2010 5:57 pm

Re: problem with 'Vector / Wind Barb Colored by Speed'

Post by bobc »

Hi HP -

I'm glad that things are working better for you. There are a couple ways that you can set the default color scale for the barbs/vectors, but the easiest way would be using a parameter default. Here's the steps for setting that up:

  1. Go to the Formula Editor for your derived oceanographic wind vectors field. Make note of how you have 'Name' at the top of the Formula Editor set. This is what you want to pass through the parameter defaults.
  2. Open the Parameter Defaults Editor (from the Main Display go to Tools>Parameters>Defaults).
  3. From the Parameter Defaults Editor window, select File>New Row.
  4. From the new Parameter Defaults window, for 'Parameter', enter the 'Name' you have set for your derived formula.
  5. Click the checkbox next to Color Table and select your enhancement.
  6. Click OK at the bottom of the Parameter Defaults window and close the Parameter Defaults Editor.
  7. Display your derived field and your enhancement should be used.

Please let me know if you have any questions about this.

Thanks -
Bob
User avatar
hproe
Posts: 504
Joined: Sat Nov 27, 2010 3:46 pm

Re: problem with 'Vector / Wind Barb Colored by Speed'

Post by hproe »

Thanks for the hint, Bob. I should have known it! Anyway, it is good to see it written up, in particular the 'Name' part.

HP
User avatar
hproe
Posts: 504
Joined: Sat Nov 27, 2010 3:46 pm

Re: problem with 'Vector / Wind Barb Colored by Speed'

Post by hproe »

It's a long time I have displayed ASCAT winds. With 1.6 and 1.7beta1 I discover now 2 things.

1. The formula 'Derived > flow vectors (from wind_speed & wind_dir)' recognises now the oceanographic wind convention the winds are coded in the netCDF file, and inverts the wind arrow/barb accordingly (sunsets my local formula). This is fine by me, but I cannot find it being documented.

2. I tried to change the default colour table, exactly as outlined by Bob in this thread (using the parameter name 'flowvectors'), with no success however. Can you repilcate this?

HP
User avatar
bobc
Posts: 988
Joined: Mon Nov 15, 2010 5:57 pm

Re: problem with 'Vector / Wind Barb Colored by Speed'

Post by bobc »

Hi HP -

#1 - You are correct about this, I'm replicating that the oceanographic wind vectors are now being handled properly. Thanks for reporting this. I'll add a note of this to the documentation.

#2 - I'm replicating this as well. It looks like the parameter default for Vector/Wind Barb Colored By Speed now needs to be set to the name of the color-by field. For example, to set a parameter default for 'Vector Colored by Speed', you would need to set the 'Parameter' in the parameter default as 'windspeed'. 'windspeed' is the Name used for the derived formula of Speed. I'll clarify this in the documentation. If you give this a try and run into any problems, please let me know.

Thanks -
Bob
User avatar
hproe
Posts: 504
Joined: Sat Nov 27, 2010 3:46 pm

Re: problem with 'Vector / Wind Barb Colored by Speed'

Post by hproe »

Hi Bob -

That's fine. I got #2 working. I also noted that the user default overrides then the system default (have overlooked this item before!).

thanks, HP
Post Reply