[R] Graphics Question

2010-02-18 Thread Lanna Jin
of the plots stacked on top of each other with the same axis dimensions and ranges. Thanks for your help in advance! -- Lanna Jin lanna...@gmail.com 510-898-8525 [[alternative HTML version deleted]] __ R-help@r-project.org mailing list http

[R] function to create multiple matrices

2010-03-10 Thread Lanna Jin
a function? Thanks in advance for your suggestions! -- Lanna Jin lanna...@gmail.com 510-898-8525 [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting

[R] Fwd: function to create multiple matrices

2010-03-11 Thread Lanna Jin
, measure='PlotFreq') x.binary <- cast(x.m, Year + LocationID ~ SpeciesCode, length) On Thu, Mar 11, 2010 at 10:55 AM, Lanna Jin wrote: >>>> >>>>> Hi Jim, >>>>> >>>>> Here's an example of what I mean by a binary matrix ( 1

[R] nested looping functions and dataframes

2010-03-16 Thread Lanna Jin
have searched through the R-help archives for hints, which have not been successful in answering my question. As a new user to R and programming languages, I truly appreciate your help and thank you for your patience. Thanks in advance for your response, Lanna Jin - Lanna Jin lanna...@gmai

Re: [R] nested looping functions and dataframes

2010-03-16 Thread Lanna Jin
Department of Statistics > UC Berkeley > spec...@stat.berkeley.edu > > > On Tue, 16 Mar 2010, Lanna Jin wrote: > > >> Hey All, >> >> So, I am confused how exactly to use nesting loop fu

Re: [R] Dynamische Programmierung mit R

2010-04-30 Thread Lanna Jin
Weiss ich nicht genau ob es in R gibt, aber versuch mal Processing.org - Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/Dynamische-Programmierung-mit-R-tp2076695p2076909.html Sent from the R help mailing list archive at Nabble.com

Re: [R] short question about data frame manipulation

2010-04-30 Thread Lanna Jin
df[1:2]<-df[1:2]*-1 ----- Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/short-question-about-data-frame-manipulation-tp2076891p2076899.html Sent from the R help mailing list archive at Nabble.

Re: [R] Delete rows with duplicate field...

2010-05-03 Thread Lanna Jin
Try, unique(dataset[,1:a]), where a is the number of columns that you have. 1:a would apply the unique to all columns. - Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/Delete-rows-with-duplicate-field-tp2123939p2123976.html Sent

Re: [R] Delete rows with duplicate field...

2010-05-03 Thread Lanna Jin
Did you try: if x is the data frame, unique(x)? - Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/Delete-rows-with-duplicate-field-tp2123939p2123956.html Sent from the R help mailing list archive at Nabble.com

Re: [R] Delete rows with duplicate field...

2010-05-03 Thread Lanna Jin
if that doesn't work, maybe also try: if x is your data frame with length a columns, "unique(x[,1:a])". - Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/Delete-rows-with-duplicate-field-tp2123939p2123964.html Sent

Re: [R] Delete rows with duplicate field...

2010-05-03 Thread Lanna Jin
names() - Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/Delete-rows-with-duplicate-field-tp2123939p2124036.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r

Re: [R] How to replace all values in a data.frame with another ( not 0) value

2010-05-04 Thread Lanna Jin
Try: "x[which(is.na(x)),] <- 000/000", where is x is your data frame ----- Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/How-to-replace-all-NA-values-in-a-data-frame-with-another-not-0-value-tp2125458p2125464.html Se

Re: [R] How to replace all values in a data.frame with another ( not 0) value

2010-05-04 Thread Lanna Jin
Whoops, my bad. Maybe try using "gsub" ----- Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/How-to-replace-all-NA-values-in-a-data-frame-with-another-not-0-value-tp2125458p2125471.html Sent from the R help mailing list

[R] R for web browser

2010-05-04 Thread Lanna Jin
Hi Everyone, Does anyone know of any projects for running an interactive R session within a web browser? I'm looking for something similar to the one on the Ruby website (http://tryruby.org), except for R. Thanks for your responses in advance! Lanna - Lanna Jin lanna...@gmail.com 51

[R] zeros keep dropping

2009-10-26 Thread Lanna Jin
Hello All! I am trying to plot the frequency of species coocurrance. If given a data set similar like this...(V1="species A", V2="species B", V3="frequency of cooccurance") > data V1 V2 V3 1 A B 0 2 A C 2 3 A D 5 4 B C 0 5 B D 1 6 C D 0 > data1<-as.data.frame(lapply(data,funct

[R] Interactive R Learning Website

2010-06-21 Thread Lanna Jin
) http://science.nature.nps.gov/im/monitor/stats/sandbox Thanks! Lanna Jin - Lanna Jin lanna...@gmail.com 510-898-8525 -- View this message in context: http://r.789695.n4.nabble.com/Interactive-R-Learning-Website-tp2263270p2263270.html Sent from the R help

[R] adjusting levelplot color scale to data

2011-11-06 Thread Lanna Jin
Hi guys, I have a matrix with values varying from approximately -0.7 to 0.33 that I want to create a heatmap/levelplot with. When I execute the levelplot function for my matrix, I end up getting colors that are adjusted to the max and min rather than around 0. In other words, ideally I would like

[R] Retrieving matrix column and row names by index value

2012-03-29 Thread Lanna Jin
Hi all, So let's say I have a matrix, mdat and I only know the index number. How do I retrieve the column and row names? For example, > mdat <- matrix(c(1,2,3, 11,12,13), nrow = 2, ncol=3, byrow=TRUE, dimnames = list(c("row1", "row2"), c("C.1", "C.2"