旋转表面图时字体颜色发生变化我已经使用确定的筛选设计中的预测公式生成了表面图。
我想在情节旋转的演示文稿中介绍我的情节。 为此,我遵循以下线程: https://community.jmp.com/t5/Discussions/Spinning-a-Scatterplot-3D/td-p/6510
这里的建议原本是针对散点图的,但是我使用同一行代码使它起作用:
Set Spin( 0.01, 0, 0.01, 0 )
旋转效果很好,但是当绘图旋转时,字体颜色从黑色变为浅灰色,使它们更难以阅读:
旋转时
固定的
有谁知道是什么原因造成的/如果我有什么办法可以解决此问题? 还是以其他方式使表面图旋转而不导致此问题?
谢谢
图形脚本编写回复:旋转表面图时,字体颜色会改变哇! 那是一个非常美丽的视觉!
当我使用Set Spin()时,我得到相同的行为。 但是,当我使用单击并拖动来手动旋转图时,却没有。
我不确定是什么原因导致的,或者是否有解决方法。 您可能需要联系技术支持( support@jmp.com )。 我在下面粘贴了一个示例脚本,该脚本演示了您在谈论使用Tiretread示例数据时遇到的问题。
除此之外,您还可以仅屏幕记录手动绘制的图形。
问候,
菲尔
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Tiretread.jmp" );
obj = Surface Plot(
Columns( :Pred Formula ABRASION ),
Control Panel( 0 ),
Surface Color Theme( "Green to Black to Red" ),
Surface Color Theme2( "Green to White to Red" ),
Surface Color Theme3( "White to Black" ),
Surface Color Theme4( "Blue to Gray to Red" ),
Response Column Color Theme( "Blue to Green to Red" ),
Response Column Color Theme2( "Blue to Gray to Orange" ),
Response Column Color Theme3( "Spectral" ),
Response Column Color Theme4( "Jet" ),
Formula( "Pred Formula ABRASION" ),
Surface Color Method( "Solid", "Solid", "Solid", "Solid" ),
SetVariableAxis( :SILICA, Axis Data( {} ) ),
SetVariableAxis( :SILANE, Axis Data( {} ) ),
SetZAxis( :Pred Formula ABRASION, Current Value( 125 ), Axis Data( {} ) ),
SetXVariable( :SILICA ),
SetYVariable( :SILANE ),
Iso Value( 0, 139.119238722664 ),
Frame3D(
Set Graph Size( 470, 470 ),
Set Grab Handles( 0 ),
Set Hide Lights Border( 1 ),
Set Rotation( -66.7809360215981, 3.32558351899253, 44.6221502352661 )
)
);
obj << Frame3D( Set Spin( 0.1, 0, 0.01, 0 ) );回复:旋转表面图时,字体颜色会改变它故意变暗,以减少文本的干扰。 标记的轴已经在切换,以避开图形,并且当纯黑色时很难观察。 我不知道有任何方法可以禁用该功能。 要扩展Phil的建议,您可以编写Frame3D << setRotation方法的脚本并捕获图像。@davidbarbour
(或者,它足够快,您可能只运行脚本而不捕获图像。)
dt = Open( "$SAMPLE_DATA/Tiretread.jmp" );
obj = Surface Plot(
Columns( :Pred Formula ABRASION ),
Control Panel( 0 ),
Surface Color Theme( "Green to Black to Red" ),
Surface Color Theme2( "Green to White to Red" ),
Surface Color Theme3( "White to Black" ),
Surface Color Theme4( "Blue to Gray to Red" ),
Response Column Color Theme( "Blue to Green to Red" ),
Response Column Color Theme2( "Blue to Gray to Orange" ),
Response Column Color Theme3( "Spectral" ),
Response Column Color Theme4( "Jet" ),
Formula( "Pred Formula ABRASION" ),
Surface Color Method( "Solid", "Solid", "Solid", "Solid" ),
SetVariableAxis( :SILICA, Axis Data( {} ) ),
SetVariableAxis( :SILANE, Axis Data( {} ) ),
SetZAxis( :Pred Formula ABRASION, Current Value( 125 ), Axis Data( {} ) ),
SetXVariable( :SILICA ),
SetYVariable( :SILANE ),
Iso Value( 0, 139.119238722664 ),
Frame3D(
Set Graph Size( 470, 470 ),
Set Grab Handles( 0 ),
Set Hide Lights Border( 1 ),
//Set Rotation( 10, 20, 30 )
)
);
//oscillate using cosine
ipic=0;
For( n = 1, n <= 3, n += 1,
For( i = 0, i < 1, i += 1 / 32,
delta = 5 * Cos( 2 * Pi() * i ); // 5 * (1..-1..1)
obj << frame3d( setrotation( 10 + delta, 20 + delta, 30 + delta ) );
obj << updatewindow;
Wait( 0 );
// take picture here if wanted
//img = report(obj)[SceneBox(1)]<<GETPICTURE></GETPICTURE>
振荡3D表面
我用gifsicle制作了动画gif;有很多方法可以将图像序列转换为动画gif或视频。
gifsicle -O3 -d 10 --loop = 0 surf * .gif> osc.gif