You can use a table to compare your predicted values and the response.
Here is an example: http://www.cyclismo.org/tutorial/R/tables.html
On Thu, Aug 2, 2012 at 5:52 AM, Abraham Mathew wrote:
> I'm developing a naive bayes in R. I have the following data and am trying
> to predict on returned (cl
I'm developing a naive bayes in R. I have the following data and am trying
to predict on returned (class).
dat = data.frame(home=c(0,1,1,0,0), gender=c("M","M","F","M","F"),
returned=c(0,0,1,1,0))
str(dat)
dat$home <- as.factor(dat$home)
dat$returned <- as.factor(dat$returned)
library(e1071)
m
2 matches
Mail list logo