[Thread Prev][Thread Next][Index]

Re: [ferret_users] Re: Calling R in ferret



Thanks Ryo for pinpoint the source of error.

Though I don't know much about R still I am able to carry out the test in R but it would be convinent to be able to do so from within ferret.
 
I need to pass an array ( v in your example). Is this not possible?

Jagadish

From: Ryo Furue <furue@xxxxxxxxxx>
To: j_karmacharya@xxxxxxxxx
Cc: ferret_users@xxxxxxxx
Sent: Friday, February 15, 2013 9:14 PM
Subject: Re: [ferret_users] Re: Calling R in ferret

Jagadish,

>I attempted to call a normality test in R from within ferret without success.
>
>yes? list strfloat(spawn("echo 'cat(shapiro.test(`v1`))' | R --slave --vanilla"))
> **ERROR: invalid command: grave accent doesnt evaluate to scalar

What argument(s) does shapiro.test() require?  (I not nothing about R.)

The error you get is exactly what the error message states.
The grave accent evaluation works only on a scalar:

yes? let v = {1, 4, 9, 16}
yes? say `v`
**ERROR: invalid command: grave accent doesnt evaluate to scalar
          v
yes? let u = 2
yes? say `u`
!-> MESSAGE/CONTINUE 2
2
yes?

Ryo



[Thread Prev][Thread Next][Index]
Contact Us
Dept of Commerce / NOAA / OAR / PMEL / Ferret

Privacy Policy | Disclaimer | Accessibility Statement