similar to: Memory leakage from large lists

Displaying 20 results from an estimated 1100 matches similar to: "Memory leakage from large lists"

2018 Jul 17
0
Memory leakage from large lists
This looks like a case of FAQ 7.42: https://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-is-R-apparently-not-releasing-memory_003f On Mon, Jul 16, 2018 at 2:32 PM, Daniel Raduta <datudar at gmail.com> wrote: > Hello, > > I am experiencing a very noticeable memory leak when using large lists of > large data. The code below creates a list of matrices, yet the memory does > not
2018 Jun 22
1
Bug in as.Date or strptime?
Hello, This just came up in SO, sessionInfo() at the end. https://stackoverflow.com/questions/50988018/seeking-explanation-for-as-date-function-in-r?noredirect=1#comment88971055_50988018 # example 1 # not even the month is right as.Date(x = 1, format = '%j', origin= '2015-01-01') #[1] "2018-07-21" # example 2a # nonsense output as.Date(x = 1, origin=
2018 May 09
3
NAs produced by integer overflow, but only some time ...
I have problem with integer overflow that I cannot understand. I have a character vector curr.lemmas with the following properties: length(curr.lemmas) # 61224 length(unique(curr.lemmas)) # 2652 That vector is the input to the following function: yules.k1 <- function(input) { m1 <- length(input); temp <- table(table(input)) m2 <- sum("*"(temp,
2018 May 09
0
NAs produced by integer overflow, but only some time ...
a) Numeric values may be either integers (signed 32 bit) or double precision (53 bit mantissa). b) Double precision constants are numeric with no decoration (e.g. 61224). Integer constants have an L (e.g. 61224L). c) 61224*61224 > 2^31-1 so that answer cannot fit into an integer. d) Exponentiation is a floating point operation so the result of 61224L^2L is a floating point answer that CAN
2008 Apr 05
2
Adding a Matrix Exponentiation Operator
Hi all I recently started to write a matrix exponentiation operator for R (by adding a new operator definition to names.c, and adding the following code to arrays.c). It is not finished yet, but I would like to solicit some comments, as there are a few areas of R's internals that I am still feeling my way around. Firstly: 1) Would there be interest in adding a new operator %^% that performs
2010 Nov 10
2
Parallel code runs slower!
My parallel code is running slower than my non-parallel code! Can someone pls advise what am I doing wrong here? t and tTA are simple matrices of equal dimensions. #NON PARALLEL CODE nCols=ncol(t) nRows=nrow(t) tTA = matrix(nrow=nRows,ncol=nCols) require(TTR) system.time( for (i in 1:nCols) { x = t[,i] xROC = ROC(x) tTA[,i]=xROC } ) user system elapsed 123.24 0.07 123.47 #
2010 Jun 10
3
Retrieving the 2 row of "dist" computations
Dear R Gurus, As you probably know, dist calculates the distance between every two rows of data. What I am interested in is the actual two rows that have the least distance between them, rather than the numerical value of the distance itself. For example, If the minimum distance in the following sample run is d[14], which is .3826119, and the rows are 4 & 6. I need to find a generic way to
2003 May 01
2
What' wrong?
I try to do single proportion test on my category data. Here is my R script: library("ctest") catSignifTest <- function( catFile ) { ############################################################### ## Get the data sets from text file catData <- read.table( catFile ) ncols <- length(catData) nrows <- length(catData[,1]) ncol1 <- ncols - 1 probeNbr
2011 Apr 18
2
Avoiding loop
Hi everyone. I'm using matrix product such as : #Generate some data NCols = 5 NRows = 5 A = matrix(runif(NCols*NRows), ncol=NCols) B = matrix(runif(NCols*NRows), ncol=NCols) #First calculation R = A%*%B for(i in 1:100) { R = R%*%B } I would like to know if it was possible to avoid the loop by using something like mapply or anything else. Tx in advance, Phil -- View this message
2019 Mar 12
3
as.data.frame.table() does not recognize default.stringsAsFactors()
Reporting a possible inconsistency or bug in handling stringsAsFactors in as.data.frame.table() Here is a simple test > options()$stringsAsFactors [1] TRUE > x<-c("a","b","c","a","b") > d<-as.data.frame(table(x)) > d x Freq 1 a 2 2 b 2 3 c 1 > class(d$x) [1] "factor" >
2004 Dec 09
2
a question about swap space, memory and read.table()
Hi all Two computers: one is my desktop PC, windows2000, R 1.9.1. Physical RAM 256MB, Swap (Virtual memory) 384Mb. When I allocate a large matrix, it firstly uses up RAM, then use swap space. In windows' task manager, the usage of memory could exceed my physic RAM's size. The other machine is a remote server. Windows XP, R 1.9.1 Physical RAM 2GB. Swap space 4GB. I use "R
2013 Jan 16
1
dendrogram stops!
Dear I am using the 'as.dendrogram' function from the 'stats' library to convert from an hclust object to a dendrogram with a dataset of size ~30000 (an example code is below). I need the dendrogram structure to use the "dendrapply" and "attributes" functions and to access the child nodes, I do not need any of the plot properties. The problem is that it
2004 Feb 26
6
adding header info to write.table
Hello, Could someone please tell if there is a way to append header info to the top of an exported dataframe (exported with write.table). I want to append the following, which are the defininitions for an asciigrid: ncols 532 nrows 999 xllcorner 510465 yllcorner 4766375 cellsize 30 NODATA_value -9999 Thanks very much, femke [[alternative HTML version deleted]]
2018 May 24
2
Problem with adding a raster and a brick
Hi, I seem to be having a problem adding the following two raster objects together - one is a rasterLayer, the other is a rasterBrick. The extent, resolution, and origin are the same, so according to my understand it should work. The objects look like so: > obs.clim class : RasterLayer dimensions : 60, 200, 12000 (nrow, ncol, ncell) resolution : 0.5, 0.5 (x, y) extent : -70,
2008 Mar 07
1
Help with 'memory not mapped'
Hi, I'm no expert programmer at all; I'm running an R script ("mariam1_2.R"). This scripts calls another script, which contains an R function, which .Call some C code. It runs several times without any problem, but sometimes I get the error: ------- *** caught segfault *** address 0x1c404ec8, cause 'memory not mapped' Traceback: 1: .Call("rrfunc",
2018 Jul 08
2
consider running tools::compactPDF(gs_quality = "ebook")
Dear all, I run R CMD build --compact-vignettes="both" gRbase and/or R CMD build --compact-vignettes="gs+qpdf" gRbase and in the log from r-devel (on winbuilder) I get * checking sizes of PDF files under 'inst/doc' ... WARNING 'gs+qpdf' made some significant size reductions: compacted 'gRbase-arrays.pdf' from 421Kb to 115Kb consider
2018 Jul 08
2
consider running tools::compactPDF(gs_quality = "ebook")
Dear all, I run R CMD build --compact-vignettes="both" gRbase and/or R CMD build --compact-vignettes="gs+qpdf" gRbase and in the log from r-devel (on winbuilder) I get * checking sizes of PDF files under 'inst/doc' ... WARNING 'gs+qpdf' made some significant size reductions: compacted 'gRbase-arrays.pdf' from 421Kb to 115Kb consider
2018 May 09
1
NAs produced by integer overflow, but only some time ...
Printing a number does not show whether it is stored as a 32-bit integer or as a 64-bit floating point value. Use. e.g., str() or class() to see. > str(length(runif(3))) int 3 > str(length(runif(3)) + 1) num 4 > str(length(runif(3)) + 1L) int 4 > str( 3L * 3L ) int 9 > str( 3L ^ 2L ) num 9 You are right that various arithmetic operators map a pair of
2011 Aug 24
3
Efficient way to Calculate the squared distances for a set of vectors to a fixed vector
I am pretty new to R. So this may be an easy question for most of you. ? I would like to calculate the squared distances of a large set (let's say 20000) of vectors (let's say dimension of 5) to a fixed vector. ? Say I have a data frame MY_VECTORS with 20000 rows and 5 columns, and one 5x1 vector y. I would like to efficiently calculate the squared distances?between each of the 20000
2018 Jul 26
2
Random behavior of mclapply
Hi, I wondered about the behavior described in the following stackoverflow question: https://stackoverflow.com/questions/20674538/mclapply-returns-null-randomly More specifically, I would like to know if you ever considered the suggestion made in the comments of the first answer, namely to somehow warn the user if one of the processes has been killed by the out-of-memory killer ? I am always