similar to: String manipulation, insert delim

Displaying 20 results from an estimated 4000 matches similar to: "String manipulation, insert delim"

2007 Dec 20
2
factor manipulation: edgelist to a matrix?
Hello All, I have had considerable bad luck with attempting the following with for loops. Here is the problem: # Suppose we have a data.frame with the following data, which can be considered a type of edgelist (for those with networks backgrounds): # # V1 V2 # 1 A # 1 A # 1 B # 2 A # 3 C # 3 A # 3 C # 3 B # # I want the output of the function to produce a matrix, such that #each factor of
2007 Aug 24
1
uneven list to matrix
Hello, I am sure I am not the only person with this problem. I have a list with n elements, each consisting of a single column matrix with different row lengths. Each row has a name ranging from A to E. Here is an example: alph[[1]] A 1 B 2 C 3 D 4 alph[[2]] A 1 C 3 D 4 alph[[3]] A 1 D 4 E 5 I would like to create a matrix from the elements in the list with n columns such that the row names
2008 Apr 03
2
iterative loop with user input?
Hello R-Users, I would like to use an iterative loop to collect user input from within a function. I'm sure that this would be some combination of "for","break", and "next" but have not been able to get the syntax down. I would like to print some text to the screen at each step in the loop, ask the user for input which is saved in an object, and then advance the
2011 May 05
6
Averaging uneven measurements by time with uneven numbers of measurements
I have a new device that takes measurements anywhere from every second, to every 15 minutes (depending on changes). The matrix has a date, time and Y column (Y is the measurement). For three days it is 25,000 rows. How do I average the measurements by every 30 minutes so my matrix is 48 rows per day? I have been working on this and cannot figure out a simple method. Any ideas? Thank you. ----- In
2011 Mar 16
4
fetch uneven
Hi I have a vector m: m [1] "ABC transporters" [2] "2" [3] "Acetyl-CoA" [4] "1" [5] "Energie" [6] "1" [7] "FAD Biosynthese"
2012 May 02
5
uneven vector length issue with read.zoo?
I truncated and simplified my code and the read in data that I'm working with to isolate the issue. Here is the read in data and R script respectively: http://r.789695.n4.nabble.com/file/n4604287/test.csv test.csv http://pastebin.com/rCdaDqPm Here is the terminal/R shell output that I hope the above replicates on your screen: > source("elecLoad.r", echo = TRUE) > #Load
2009 Oct 02
2
how to fill out the empty spots when using rbind or cbind?
I have uneven vectors I want to use cbind or rbind to combine them into a matrix. Is there a way to make it so that R would not return error msg saying they're uneven? Thanks. Edward Chen Email: tkedch@msn.com Cell Phone: 510-371-4717 [[alternative HTML version deleted]]
2007 Jul 03
2
Problems using imported data
(Repeat of previous HTML version) Hello all, I am a new R user and I have finally imported my data using >read.delim("Filename.txt", header=TRUE) after some difficulty, by changing file directories (a hint to anyone who might be stuck there). However, I am now stuck trying to use my data. When I try to use data.frame("filename.txt") it tells me object not found, which
2012 Dec 17
11
[Puppet Upgrade] Puppet agent does not work
I upgraded Puppet master from 2.7.6 to 2.7.20 on CentOS5.8_x86_64. But when I tried to launch ''puppet agent -t'' on one of staging servers, the puppet daemon did not work and got heaps errors. I have no idea what made it wrong and how to fix it. Retrieving plugin [0m Failed to generate additional resources using ''eval_generate: Error 500 on SERVER: <!DOCTYPE HTML
2011 Mar 03
2
plot, y-axis, uneven scale???
Hello, I have a question about the y-axis of plots. Actually I had about 60 values. About 80 percent of these values are less than 0.2, then the other 20 percent values are more than 4,max is 10. So when I plot these values together, the y-axis's range will go 0 to 10, and my major values (80% values <0.2) will be pressed around 0 on the bottom, while other several dots will scatter in
2012 Sep 27
3
Drawing asymmetric error bars
Hello, I have data which I have arcsin transformed to analyse. I want to plot my data with error bars however as my data is back-transformed my standard errors are uneven. Is there a simple way to draw these asymmetric error bars in R? Thanks for your help. [[alternative HTML version deleted]]
2012 Feb 08
2
Problems reading tab-delim files using read.table and read.delim
Hello, I used read.xlsx to read in Excel files but for large files it turned out to be not very efficient. For that reason I use a programme which writes each sheet in an Excel file into tab-delim txt files. After that I tried using read.table and read.delim to read in those txt files. Unfortunately, the results are not as expected. To show you what I mean I created a tiny Excel sheet with some
2008 Mar 13
3
Splitting a set of vectors in a list
I have a set of character vectors of uneven length that I have stored in a list. I can easily enough get any column of them using lapply but what I want is to be able to create a matrix of them. Other than some kind of brute force looping approach I have drawn a blank. Would somebody please suggest something? Thanks Example. mylist <- list(aa=c("cat","peach" ),
2005 Sep 08
1
Wishlist: write.delim()
Hi, It would be great if someone would add write.delim() as an adjunct to write.table(), just as with write.csv(). I store a lot of data in tab-delimited files and can read it in easily with: read.delim("text.txt", as.is=TRUE) and would love to be able to write it out as easily when I create these files. The obvious setting needed for write.delim() is sep = "\t", but in
2009 Sep 23
1
read.delim very slow in reading files with lots of columns
Hi, I am trying to read a tab-delimited file into R (Ver. 2.8). The machine I am using is 64bit Linux with 16 GB. The file is basically a matrix(~600x700000) and as large as 3GB. The read.delim() ran extremely slow (hours) even with a subset of the file (31 MB with 6x700000) I monitored the memory usage, and found it constantly only took less than 1% of 16GB memory. Does read.delim()
2010 Jul 28
2
read.delim()
I am reading in a very large file with names in it and R is truncating the number of rows it reads in. The separator in this file is a pipe '|' and so I use dat <- read.delim('pathToMyFile', header= TRUE, sep='|') It turns out that it is reading up to row 61145 and stopping and I think I see why, but am not sure of the best solution to this problem. I see the name of
2014 Jul 01
1
combining data from multiple read.delim() invocations.
Is there a better way to do the following? I have data in a number of tab delimited files. I am using read.delim() to read them, in a loop. I am invoking my code on Linux Fedora 20, from the BASH command line, using Rscript. The code I'm using looks like: arguments <- commandArgs(trailingOnly=TRUE); # initialize the capped_data data.frame capped_data <- data.frame(lpar="NULL",
2005 Apr 18
2
colClasses = "Date" in read.delim, how to pass date-format?
Hi I have a huge data-set with one column being of type date. Of course I can import the data using this column as "factor" and then convert it later to dates, using: sws.bezuege$FaktDat <- dates(as.character(sws.bezuege$FaktDat), format = c(dates = "d.m.y")) But the conversion requires a huge amount of memory (and time), therefore I would
2012 May 04
2
read.table() vs read.delim() any difference??
Hi, I have a tab seperated file with 206 rows and 30 columns. I read in the file into R using read.table() function. I checked the dim() of the data frame created in R, it had only 103 rows (exactly half), 30 columns. Then I tried reading in the file using read.delim() function and this time the dim() showed to be 206 rows, 30 columns as expected. Reading the read.table() R-help documentation, I
2004 Mar 04
1
1.9.0-devel: _ in read.delim and make.names
In R 1.9.0, make.names will accept "_" as a valid character for a syntactically valid name. I would appreciate to have an option in ``read.delim'' (etc.) that would change "_" in headers of input files to "." for compatibility with code and data written for R 1.8.1 and before. Wolfram Fischer