|
From: Mario R. <bio...@te...> - 2018-08-30 09:27:27
|
El 30/08/18 a las 10:44, Soegtrop, Michael escribió: > > Dear Mario, > > > enhanced3d=[2*z-1,x,y,z], > > this doesn’t help, because with this the graph is wrong. The second > graph has range of 0..1 and should only use the colors from 0..1. With > your suggestion the plot suggests that the range of the second > function is -1..1, it is identical to plotting 2*f-1, but I want to > plot f. > > Best regards, > > Michael > > I understand. A possible trick is to play with option palette in the following way. In the first plot, -1 is represented as red, 0 as blue, 1 as salmon, and the rest of z values are interpolated. In the second plot, 0 is blue, and 1 is salmon. wxdraw( columns=2, gr3d( view=map, enhanced3d=true, xlabel="a", ylabel="b", proportional_axes=xy, palette = [red, blue, salmon], explicit(lambda([a,b],sin(%pi*(a+b))),a,-1,1,b,-1,1)), gr3d( view=map, enhanced3d=true, xlabel="a", ylabel="b", proportional_axes=xy, palette = [blue, salmon], explicit(lambda([a,b],sin(%pi*(a+b))^2),a,-1,1,b,-1,1)) ); -- Mario http://www.tecnostats.net |