R-programming issue with ImageMagick -


i trying create animation using r , imagemagicks.

here simple code plots 5 different values of x,y , z on 3dscatterplot.

simulator=function() {   library(scatterplot3d)   for(i in 1:5)   {   png(paste(i,'plot.png',sep=''))   scatterplot3d(i*10,i*10,i*10,                 main="quadcopter simulator",                 xlab = "x-axis",                 ylab = "y-axis",                 zlab = "z-axis",                 xlim=c(0,100),                 ylim=c(0,100),                 zlim=c(0,100),                 box=false)   dev.off()   } } 

after 5 .png images in working directory.

then have manually open command prompt , type these commands:

1) cd c:/users/.... (location .png's are) 2)convert *.png -delay 1000 -loop 0 animation.gif

this works , creates .gif of .png @ same location.

when try same including in r script adding end:

system('c:\program files\imagemagick-7.0.3-q16\convert.exe" -delay 80 *.png example_1.gif',intern = true)

it says :

error in system("c:\program files\imagemagick-7.0.3-q16\convert.exe\" -delay 80 *.png example_1.gif", : 'c:\program' not found

i in dilemma how address issue.

so sum problem want somehow run command prompt commands through r-script. can please me same.

thanks alot guys patience , time.


Comments

Popular posts from this blog

java - SSE Emitter : Manage timeouts and complete() -

jquery - uncaught exception: DataTables Editor - remote hosting of code not allowed -

java - How to resolve error - package com.squareup.okhttp3 doesn't exist? -