안녕하세요. 저는 JMP를 처음 사용하는데 질문이 있습니다. 애니메이션을 저장할 수 있나요?
예를 들어 일부 테이블에서 Fit Y by X를 수행한 다음 데이터 필터 애니메이션을 사용하는 경우입니다. 애니메이션/클립을 저장할 수 있습니까?
감사해요!
여기에서 데이터 필터를 사용하여 애니메이션 GIF를 저장하는 또 다른 예를 찾을 수 있습니다. 데이터 필터 애니메이션을 애니메이션 GIF로 저장 .
Windows에서 JMP 13을 사용하는 경우 애니메이션 GIF를 생성하는 새로운 JSL 기능을 사용하여 데이터 필터 애니메이션을 저장할 수 있습니다.
다음은 로컬 데이터 필터를 사용하여 그래프 빌더를 생성하고 애니메이션 GIF를 저장하고 여는 예입니다. 자세한 내용은 다음을 확인하세요. @존폰테 '에스 Bubble Plot을 사용한 애니메이션 GIF에 대한 게시물 . 나는 아래 스크립트의 허리케인 예제에서 많은 코드를 빌렸습니다. 이론적으로 이는 "report = Current Report()" 줄로 시작하는 모든 항목을 실행하는 경우 열려 있는 현재 창에서 작동할 수 있습니다.
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\Big Class.jmp" );
gb = dt << Graph Builder(
Show Control Panel( 0 ),
Variables( X( :height ), Y( :weight ), Overlay( :sex ) ),
Elements( Points( X, Y, Legend( 1 ) ), Smoother( X, Y, Legend( 2 ) ) ),
Local Data Filter(
Add Filter(
columns( :age ),
Where( :age == 12 ),
Display( :age, Size( 202, 114 ), List Display )
)
)
);
report = Current Report();
ldf_listBox = report[ListBoxBox(1)];
numLevels = NItems(ldf_ListBox << Get ITems);
// Create a new image, same size as the graph we are going to capture
graphFrame = report[FrameBox(1)] << getPicture();
{w, h} = graphFrame << getSize();
img = newImage(w, h);
for(i=1,i<=numLevels,i++,
// deselect old selection
selectedItems = ldf_listBox << Get Selected Indices;
for(k=1,k<=nitems(selectedItems),k++,
ldf_listBox << set selected(selectedItems[k],0);
);
// set the next item selected
ldf_listBox << set selected(i);
wait(0); // wait for the display to update
// Capture frame for current graph and save to animated image
graphFrame = report[FrameBox(1)] << getPicture();
{r, g, b} = graphFrame << getPixels("rgb");
img << addFrame();
img << setFrameDuration(1000); // Time between frames, in ms
img << setPixels("rgb", {r, g, b});
wait(0.5); // for demonstration purposes
);
// Remove inital blank frame
img << removeFrame(0);
// Write out animated image
img << saveImage ("$temp\animated.gif", gif);
// open the gif
open("$temp\animated.gif");
결과 GIF 파일을 추가하도록 편집되었습니다.
Resulting animated gifResulting animated gif 결과 애니메이션 GIF