Displaying 3 results from an estimated 3 matches for "barow".
Did you mean:
baron
2009 May 22
2
Scope problem?
I've just spent today trying to fix a Heisenbug...
this function returns a linear interpolator function:
interpOne <- function(xl,yl){
f = function(data){
t = (data-min(xl))/(max(xl)-min(xl))
return(min(yl)+t*(max(yl)-min(yl)))
}
return(f)
}
> k=interpOne(c(0,1),c(4,5))
> k(0.5)
[1] 4.5
and this function uses the above to return a function that returns a
piece-wise
2006 Nov 03
1
(no subject)
...il.gmail.com>
<454B8521.60707 at sgul.ac.uk>
<efb536d50611031012k7594bbdw3727d20f1c617740 at mail.gmail.com>
<454B8CAE.6060602 at lancaster.ac.uk>
X-Mailer: VM 7.19 under Emacs 21.4.1
Reply-To: Martin Maechler <maechler at stat.math.ethz.ch>
>>>>> "BaRow" == Barry Rowlingson <B.Rowlingson at lancaster.ac.uk>
>>>>> on Fri, 03 Nov 2006 18:38:38 +0000 writes:
BaRow> Sarah Goslee wrote:
>> Since this step works,
>>
>> mental$Rx <- factor(mental$Rx, levels=c("VS","IPS...
2002 Dec 04
2
difftime arithmetic (PR#2345)
Full_Name: Barry Rowlingson
Version: 1.6.0
OS: RH8 i386
Submission from: (NULL) (148.88.136.205)
Strange things happen if I premultiply a difftime() object with a number.
Example:
> d1 <- difftime(Sys.time(),Sys.time())
> d2 <- 1 * difftime(Sys.time(),Sys.time())
> d3 <- difftime(Sys.time(),Sys.time()) * 1
> d1
Time difference of 0 secs
- thats fine
> d2
[1] 0