Re: [R] scientific notation in a data frame

2012-03-20 Thread Laura Rodriguez Murillo
Thank you! On Tue, Mar 20, 2012 at 8:39 PM, David Winsemius wrote: > > On Mar 20, 2012, at 7:52 PM, Laura Rodriguez Murillo wrote: > > Dear list, >> I have a data frame where one of the columns are p values with scientific >> notation mixed with regular numbers with

[R] scientific notation in a data frame

2012-03-20 Thread Laura Rodriguez Murillo
Dear list, I have a data frame where one of the columns are p values with scientific notation mixed with regular numbers with decimals. >a=data frame >a P OR N 0.50 0.7500 237 0.047 1.1030 237 0.124 0.7742 237 0.124 0.7742 237 0.0080 1.1590 237 0.50 0.7500 237 4.5e-07 1.2 237 5.6e-04 0.

[R] how to rearrange a dataframe

2010-02-23 Thread Laura Rodriguez Murillo
Hi all, I'd appreciate if anyone can help me with this... I have a data frame that looks like this: 1 + name1 1 2 3 2 + name2 5 9 10 2 - name3 56 74 93 1 - name4 65 75 98 I need to rearrange this in a way so that the rows with "1" in the first column, and "-" in the second column; then columns

Re: [R] : how to select rows at random

2009-03-27 Thread Laura Rodriguez Murillo
4 > 1830  105  817  906  825 1329 1500 1806 1623  186  352 1270 1727 1170 > 518 1743  370  964   20  710  870  248 1227  594  471  704 1751 > [41] 1942 1435 1944 1057  849 1886  290  130   48 1195 >> > > > On Fri, Mar 27, 2009 at 3:18 PM, Laura Rodriguez Murillo > wrote: &g

Re: [R] : how to select rows at random

2009-03-27 Thread Laura Rodriguez Murillo
04 16 5004 25 5004 26 5004 35 5004 36 5004 45 5004 46 5004 55 Thank you! Laura 2009/3/27 jim holtman : > ?sample > > On Fri, Mar 27, 2009 at 3:11 PM, Laura Rodriguez Murillo > wrote: >> Hi dear list, >> >> I have a list of around 2000 identifiers aranged in a dat

[R] : how to select rows at random

2009-03-27 Thread Laura Rodriguez Murillo
Hi dear list, I have a list of around 2000 identifiers aranged in a dataframe in one column and I would like to choose a random subset of these. I wonder if somebody can tell me if I could do this with R... Thank you so much! Laura RM __ R-help@r-proj

Re: [R] : put grids in a plot at specific x points

2009-03-16 Thread Laura Rodriguez Murillo
vector, vec,  then this should do the trick: > > abline(v=vec, lty="dotted") > > -- > David Winsemius > On Mar 16, 2009, at 4:25 PM, Laura Rodriguez Murillo wrote: > >> Hi dear all! >> >> I wonder if anybody can help me with this: >> >> I have a p

[R] : put grids in a plot at specific x points

2009-03-16 Thread Laura Rodriguez Murillo
Hi dear all! I wonder if anybody can help me with this: I have a plot: allchr <- read.table("allchrtog.txt", header=F) > attach(allchr) > names(allchr) [1] "V1" "V2" "V3" "V4" > plot(V1,V3, type="n") > lines(V1,V3) and I want to add grids to the plot but just at specific x points. So for examp

[R] : record which entry in one file doesn't appear in a different file

2009-02-25 Thread Laura Rodriguez Murillo
Hi dear list, If anybody could help me, it would be great! I have two files: File 1 is a list (one column and around 10 rows) File 2 is a list with all the names from file one and a few more (one column and more than 10 rows) What I want is to add a column in file 2 that says which name

[R] :How to insert a column in a data frame

2009-02-17 Thread Laura Rodriguez Murillo
Hi dear list, I wonder if somebody can help me with this. I have a text file with 300 rows and around 30 columns and I need to insert a column that has the number 1 in every row. This new column should be placed between columns 6 and 7. As an example: I would want to insert a column (consitin

Re: [R] how to delete specific rows in a data frame where the first column matches any string from a list

2009-02-06 Thread Laura Rodriguez Murillo
Thank you so much! I finally got it. Laura 2009/2/6 Sebastien Bihorel : > Hi Laura, > > You might want to read the manual on Data importation and exportation on the > cran webpage http://cran.r-project.org/ > Otherwise, have a look at ?read.table. > > Sebastien >

Re: [R] how to delete specific rows in a data frame where the first column matches any string from a list

2009-02-06 Thread Laura Rodriguez Murillo
rows. In these cases, I need to delete the entire row. I also have a file B (one column and around 28 rows) with a list of the entries that are repeated. So I was trying to look for the ones that match and get rid of the entire row. Thank you! Laura 2009/2/6 Wacek Kusnierczyk : > Laura

Re: [R] how to delete specific rows in a data frame where the first column matches any string from a list

2009-02-06 Thread Laura Rodriguez Murillo
Kusnierczyk : > Laura Rodriguez Murillo wrote: >> Hi, >> >> I'm new in the mailing list but I would appreciate if you could help >> me with this: >> I have a big matrix from where I need to delete specific rows. The >> second entry on these rows to delete sho

[R] how to delete specific rows in a data frame where the first column matches any string from a list

2009-02-06 Thread Laura Rodriguez Murillo
Hi, I'm new in the mailing list but I would appreciate if you could help me with this: I have a big matrix from where I need to delete specific rows. The second entry on these rows to delete should match any string within a list (other file with just one column). Thank you so much! Laura ___