[AniMov] Animove GUI runs in Windows!

Anne Ghisla a.ghisla at studenti.uninsubria.it
Thu May 22 16:41:18 CEST 2008

Scrive Leonardo Lami <lami at faunalia.it>:


> > I tried to patch it adding a sed command that subtitutes whitespaces with
> > underscores.
> >
> > s/\ /_/g
> >   
> > This is not a definitive solution, anyway...
> >   
> You can avoid this problem choosing an installation directory without 
> space (eg. C:\Programmi\QuantumGIS\)
> This is not a definitive solution, anyway...

Unfortunately not. As the $PATH can contain whitespaces potentially everywhere,
it is safer to remove them into the script execution. This can avoid trouble
with unuseful whitespaced paths, but if the path to R contains spaces, I can
only ask the user to remove them with external renaming tools.

> > I guess it's a problem of R for Windows. I never got this error on Ubuntu,
> > running the same code.

The problem above has been fixed, it was not caused by WinR. It was created when
in the script the GIS_OPT variables are renamed. On Windows (I ignore why) the
trailing whitespaces between = must be removed, in order to let commands work
Therefore, no substitution in R commands was performed, and this lead to errors.

The main problem I can't solve by myself is how to make R read the CSV file. 
The path proposed by the browser contains both backslashes and whitespaces. R in
Windows has the same path rules of Linux, and won't accept this form.
I tried to manually write a suitable path replacing backslashes by slashes, this
is the only solution I found... sed and regular expressions are too much
complicated when a fast solution is needed :(
There is still the whitespace problem, and in the form it is impossible to
escape spaces in R style with backslash.

I join a copy of the code. I think it needs some improvement on filenames stuff,
but it walks on its own legs :)
I commented the lines that create csv tables about convergence and h values. the
output file name could be created through a paste() command to bypass underscore
escaping trouble. I'll fix this ASAP. 



-------------- next part --------------
A non-text attachment was scrubbed...
Name: v.animove
Type: application/octet-stream
Size: 5464 bytes
Desc: not available
URL: <http://www.faunalia.com/pipermail/animov/attachments/20080522/f9a39654/attachment.obj>

More information about the AniMov mailing list