similar to: File Reading Problem

Displaying 20 results from an estimated 3000 matches similar to: "File Reading Problem"

2003 Sep 01
1
Re: [R] File Reading Problem (PR#4043)
On Mon, 1 Sep 2003 14:26:43 -0700, "Jiming Yu" <jimingyu@princeton.edu> wrote: >Dear all, > I am trying to read characters byte by byte(in their ASCII codes) from a >file I was going to suggest using readBin, but there seems to be a bug: > con <- file('c:/test.txt','rb') > readBin(con,'c',15,1) stack imbalance in internal readBin, 9
2002 Mar 05
3
reading 2-byte integers using readBin and connections
Hi folks: This may be a stupid question, but I cannot seem to find a way to tell readBin that I want to read 2-byte integers from the connection. The input file is 150,720 bytes long containing 75,360 short (2-byte) integers. But specifying "integer" or "int" for what in readBin only returns me a vector of length 37680, leading me to believe that sizeof(integer) or
2011 Mar 29
2
Reading 64-bit integers
Dear all, I see from some previous threads that support for 64-bit integers in R may be an aim for future versions, but in the meantime I'm wondering whether it is possible to read in integers of greater than 32 bits at all. Judging from ?readBin, it should be possible to read 8-byte integers to some degree, but it is clearly limited in practice by R's internally 32-bit integer type:
2006 Nov 07
1
reading VERY large binary files
Hello, I am trying to read in elements out of a very large binary file ... the total file is 4 gigs. I want to select rows out of the file, and the current procedure I run works but is prohibitively slow (takes more than a day to run and still won't complete). Is there any faster way to accomplish this? My current procedure looks like this: readHH <- function(file_name,
2009 Dec 17
1
Problem reading binaries created with fortran (More infos)
The structure of the file is clear (see below) the first line is made of integers and doubles with the fifth being a text string followed by arrays of double precision number.: int1 int2 double1 double2 text int3 int4 int5 (array of double) here is an example of file: 1 1 1.0 1.0 "HEAD" 160 224 3 23.4 34.5 ...... I tried to read the first line with readBin (results are copied below):
2009 Feb 11
1
Reading Binary Files
Hello I'm encountering some difficulty correctly reading binary files. The binary files store data as "short" rather than "double" , "int", or any of the other modes of the vector being read. The data represents a regular grid of size 419 rows by 264 columns, to make it more interesting, the data are daily records, for a total of 37 years. The file size is
2002 Jan 09
1
bug in read.table?
Hello, in the new Relase (1.4) i get a different (worser) result for read.table with as.is=T: it crash! Input file (t.txt, with a name, 5 character and a numeric column) Name short kind logable use save lag m "mo" "x" "n" "1" "n" 0 Ptp "PT" "l" "y" "m" "n" 0 R-Code
2001 Feb 15
2
Reading single precision floats from binary file
Dear all, I have a few files with binary data written by a C program a friend wrote. I allready have program to read these files, Thomas Lumley and Prof Brian D Ripley was kind enough to respond to a question to this list earlier with some code that works perfectly, so this is really no problem, it is more out curiousity. Most of my files consists of 40000 single precision floats, and I figured
2010 Jan 21
2
"stack imbalance in ..." when loading a workspace
Hi all, I just failed in loading a saved wordspace (13MB of size), and received these errors: Warning: stack imbalance in 'missing', 52 then 51 Warning: stack imbalance in 'if', 50 then 53 Warning: stack imbalance in 'as.environment', 57 then 59 Warning: stack imbalance in 'ls', 54 then 53 Warning: stack imbalance in '.Internal', 54 then 53 Warning: stack
2010 Feb 08
2
Error on start R in server
Hello all, (Thank for your reply) I have a web-application in Apache Tomcat, when i start R in this application, I used packe RSJava Code ROmegahatInterpreter interp; String [] rargs = {"--no-save"}; REvaluator e; interp = new ROmegahatInterpreter ( ROmegahatInterpreter.fixArgs(rargs),false ); e =new REvaluator (); Errors ================ R version 2.10.1 (2009-12-14)
1997 May 13
2
R-alpha: Patch2
There is a problem with the patch I sent out yesterday. The patches for the glm code are applied in the wrong place. I have removed the patch file and will have a real one available latter today. Ross =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help",
2009 May 08
1
anyDuplicated(incomp=NA) fails
With today's R 2.10.0(devel) I get: > anyDuplicated(c(1,NA,3,NA,5), incomp=NA) # expect 0 Warning: stack imbalance in 'anyDuplicated', 20 then 21 Warning: stack imbalance in '.Internal', 19 then 20 Warning: stack imbalance in '{', 17 then 18 [1] 0 > anyDuplicated(c(1,NA,3,NA,3), incomp=NA) # expect 5 Warning: stack imbalance in 'anyDuplicated', 20 then 21
2012 Jun 12
1
Reading binary files
Hey guys, I am currently trying to read in a binary file using this helpful manual: http://www.ats.ucla.edu/stat/r/faq/read_binary.htm Reading binary files I also have the detailed format description from the developer. But somehow the reading of the file does still not work properly. The first entry in the file is the following, according to the manufacturer: "String containing 4 one-byte
2007 Feb 23
1
help with RMySQL
Hi R users, I am using RMySQL to connect to a database in MySQL. I have 3 questions. 1)When I give the following command dbListTables(con) I get the output stack imbalance in .Call, 142 then 143 stack imbalance in <-, 140 then 141 stack imbalance in {, 138 then 139 stack imbalance in standardGeneric, 126 then 127 stack imbalance in class, 121 then 122 stack imbalance in
2009 Jan 06
2
Strange error message
I'm testing out some changes to survreg and got the following output, the likes of which I've never seen before: ---------------------------------------------------------------------- R version 2.7.1 (2008-06-23) Copyright (C) 2008 The R Foundation for Statistical Computing ISBN 3-900051-07-0 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it
2001 Dec 25
1
read.table (PR#1227)
Full_Name: Antonio Possolo Version: 1.4.0 OS: Linux Submission from: (NULL) (24.25.141.205) ## inputFile has the following three lines (each without the initial ``## '') ## a,b ## m,1 ## n,3 ## and resides in $HOME/R fileHOME <- paste(Sys.getenv("HOME"), "/R/", sep="") fileNAME <- "inputFile" ## Given the command, z <-
2010 Mar 25
1
RODBC : reading binary data from a TXT field belonging to a PostgeSQL table
Dear R-List, I am working with binary data that I want to store in a PostgreSQL DataBase. I decided to use a TXT field. I read my binary file with readBin function, I succeed in my data storage in the database but I have some trouble to extract the data : the correct amount of bytes is stored in the TXT field but when I access to the data, the extracted dataframe is truncated !
2002 Jan 15
1
Error message in R: stack imbalance
Hello... I just installed R version 1.4.0 on my laptop running Redhat Linux 7.1. I downloaded the RPM from CRAN and when I try to use a function I have used on other Redhat systems, I get the following error message. -------- > library(qtl) > gastritis <- read.cross(format="csv",dir="/home/sen/qtl/data/gastritis", +
2004 Mar 10
1
reading binary file with different modes
I have a binary file representing a matrix with columns of different variable type/mode (i.e. the file was saved from C using double and int variables) I want to import it into R, I've been reading the R Import/Export and I am able to use readBin for a file that contains only one variable type (either all doubles or all ints) but I can not find the way to use it when you have a file with
2008 May 29
2
Reading an "unsigned long long" using R readBin()
Sorry for the simple question, but I am trying to read an "unsigned long long" using the R readBin() function. Can someone point me in the right direction, or am I better off using C for such things? The file that I am reading will have been produced on the same machine that is doing the reading. Thanks, Sean