Profile cover photo
Profile photo
Lee Pang
92 followers
92 followers
About
Lee's posts

Post has attachment
Desktop DeployR
I'm going to be giving a talk this Thursday at my local R/Data Science Meetup about my method for deploying self contained desktop R applications. Since my original post on the subject (over 2 years ago!) I've made many of improvements thanks to the many us...

Post has attachment
Facing your data
A few years ago, I came across a post on FlowingData about using Chernoff Faces as a fun way to visualize multidimensional data: > The assumption is that we can read people 's faces easily in real life,
> so we should be able to recognize small differences...

Post has attachment
Lee Pang commented on a post on Blogger.
Glad to help!  Hope it works out as well for you as it did for us.

Post has attachment
Lee Pang commented on a post on Blogger.
So far, the fix to the problem in my post is holding.  As for your related issue, how about:

> vx <- list(x,x)
> vx
[[1]]
[1] "foo"
attr(,"myAtt")
[1] "bar"

[[2]]
[1] "foo"
attr(,"myAtt")
[1] "bar"

> vx[[1]]
[1] "foo"
attr(,"myAtt")
[1] "bar"

Post has attachment
Lee Pang commented on a post on Blogger.
Actually, +ZJ Dai I used your post as a reference for mine :)

Post has attachment
Lee Pang commented on a post on Blogger.
Nice post Chris.  Regarding your comment about not having a function that takes a fit and produces a function with predictor variables as formal arguments, how about the following:

# simple lm() fit:
xyz = data.frame(x=runif(100), y=rnorm(100), z=rnorm(100))
fit.lm = lm(z ~ x*y, xyz)

# prediction function generator:
predictfun = function(fit) {
  function(x, y) {
    predict(fit, newdata=list(x=x, y=y))
  }
}

# thus ...
f = predictfun(fit.lm)

x = rnorm(10); y = rnorm(10)
zhat = f(x, y)

Post has attachment
never hurts to experiment with "incompatible" things

Post has attachment
It's about time I figured out R packaging.

Google Docs (e.g. Writely) needs Markdown editing mode.

Post has attachment
Wait while more posts are being loaded