Re: [R] what does negative indexing in a matrix mean?

From: Stephan Kolassa <Stephan.Kolassa_at_gmx.de>
Date: Wed, 12 Nov 2008 18:46:27 +0100

"take all of the matrix *except* those indices", so XW4[,-2] is the matrix XW4 with the 2nd column *deleted*.

Cheers,
Stephan

Itziar Frades Alzueta schrieb:
> Hi,
>
> Does anyone know what the negative indexing of a matrix mean?
>
>
>
> I am using the RWeka and this evaluate classifier does not work on new
> data like this
>
>
>
> e <- evaluate_Weka_classifier(m1235,newdata=XW4, complexity =
> FALSE,class = FALSE)
>
>
>
> while it work with negative indexing:
>
>
>
> e <- evaluate_Weka_classifier(m1235,newdata=XW4[,-2], complexity =
> FALSE,class = FALSE)
>
>
>
> Although I do not understand what negative indexing of a matrix means,
> or whether it produces any transformation.
>
>
>
> Regards,
>
>
>
> Itziar Frades
>
>
>
>
>
> This e-mail is from CIC bioGUNE. The e-mail and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. Any unauthorised dissemination or copying of this e-mail or its attachments, and any use or disclosure of any information contained in them, is strictly prohibited and may be illegal. If you have received this e-mail in error, please notify or telephone + 34 944 06 13 00 and delete it from your system.
>
>
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help_at_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-help_at_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. Received on Wed 12 Nov 2008 - 17:52:10 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 12 Nov 2008 - 18:30:24 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive