[R] Array within an array

2008-04-21 Thread Carla Rebelo
Hello,

I need help to build an array within an array, i. e., I have this:

 tt[,,c(1,2)]
, , metadados.class_7.R

   CS   WRC   LRA
Inicial 1.000 1.000 1.000
Final   0.5974482 0.6095162 0.5866560
Indep   0.4335460 0.4799575 0.4169591
Inicial 0.9925572 0.9925572 0.9925572
Final   0.6079745 0.6004785 0.5708134
Indep   0.4335460 0.4799575 0.4169591
Inicial 0.2395003 0.2395003 0.2395003
Final   0.2906433 0.3400851 0.3616162
Indep   0.4335460 0.4799575 0.4169591

, , metadados.class_stat.R

   CS   WRC   LRA
Inicial 1.000 1.000 1.000
Final   0.6978175 0.711 0.5665584
Indep   0.6079365 0.6289683 0.5211580
Inicial 1.000 1.000 0.9973485
Final   0.6978175 0.711 0.5641775
Indep   0.6079365 0.6289683 0.5211580
Inicial 0.2873016 0.2873016 0.2690476
Final   0.4988095 0.5591270 0.2951840
Indep   0.6079365 0.6289683 0.5211580

How can I  divide the third dimension in more three? Thank You!

Carla Rebelo

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] Error

2008-03-07 Thread Carla Rebelo
Hello!

I need some help, because I don't know how this error means: Error: 
variables ‘Output1’, ‘Output2’, ‘Output3’, ‘Output4’, ‘Output5’ were 
specified with different types from the fit
Execution halted

Can you help me?
Thank You

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] Cross Validation

2008-02-27 Thread Carla Rebelo
Hello,

How can I do a cross validation in R?

Thank You!

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] contingency table

2008-02-14 Thread Carla Rebelo
Hello!

May you help me? I'm trying to do a contingency table using this

  data(iris)
  library(rpart)
  modelo - rpart(Species ~., iris)
  prev - predict(modelo, iris)

Finally the contingency table
  table(iris$Species, prev)
But an error occurs:
Error in table(iris$Species, prev) :
  all arguments must have the same length

And I do not understand why, may you help me?

Thank You!

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] The function predict

2008-02-11 Thread Carla Rebelo
Good Morning!

May you help me? I need to understand the function predict. I need to 
understand the algorithm implemented, the calculations associated. Where 
can I find this information?

Thank You!

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] Concatenate a Variable

2008-02-01 Thread Carla Rebelo
Good morning!

I do not speak English very well and so I will try to explain the best I 
can. I have this:

  tabela[,1]
[1] a a b b a c b a c c c c c
Levels: a b c

 unique(tabela[,1])
[1] a b c
Levels: a b c

 var-unique(tabela[,1])[1]

  var
[1] a
Levels: a b c

But if I concatenate like this
  cat(VAR: , var, \n)

I obtain
 VAR:  1

and I want to obtain
 VAR: a

How can I do this? Thanks!

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] Recursive Function

2008-01-22 Thread Carla Rebelo
It is possible to place two functions in a recursive function
Main results so as to simultaneously?
[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] Two dependent variables in formula

2008-01-09 Thread Carla Rebelo
Hello,

 I' m trying to change the formula in the rpart function. The  
format of a general formula is Answer ~ expression, where Answer is  
the dependent variable and expression is set of terms containing the  
independent variables and separated by operators. I want the response  
of the formula is more than one dependent variable. It is possible?

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.