Displaying 2 results from an estimated 2 matches for "lidaky".
2012 Feb 29
1
The joys of Nabble: Re: Cannot use negative argument in function
...e example? What are we
trying to solve? With the erroneous formatting codes removed,
the function runs, as far as I can tell.
Sarah
> should that be
>
> ?TT <- "Temp"+273.15
> or
> ?TT <- Temp+273.15
> or something else?
>
> On Wed, Feb 29, 2012 at 2:14 PM, lidaky <svfilhol at alaska.edu> wrote:
>
>> here is the code:
>>
>> index.refraction <- function(Temp,Press, RH, CO2)
>> {
>> ?#define constant
>> ?lambda ?<- ?531 #nm
>> ?Co ?<- 299792458 #m/s
>> ?ww <- c(295.235,2.6422,-0.03238,0.00402...
2012 Feb 29
3
Cannot use negative argument in function
Hi,
today i wrote a function in R of the type:
index.refraction <- function(Temp,Press, RH, CO2)
When i try to plug a negative number in Temp, i got this type of error:
"
n <- index.refraction(Temp= -40,100,80,CO2)
Messages d'avis :
1: In Ops.ordered(left, right) : '-' is not meaningful for ordered factors
2: In Ops.factor(left, right) : - not meaningful for factors
3: