similar to: Problem with zoo and rbind() converting matrix to vector

Displaying 20 results from an estimated 10000 matches similar to: "Problem with zoo and rbind() converting matrix to vector"

2009 Mar 21
1
How to avoid switching on input type?
Hi, I need some help improving this ugly code I wrote. I would like to shift forward a zoo object, matrix, ts, or list by "shift" items (default 1) and fill the holes with 0's. The code below works, but it looks ugly. I could write a function lag.zerofill() which calls the two functions below depending on the class() of the item passed in, but that feels very unlike R. What is
2008 Sep 02
1
R Newbie: quantmod and zoo: Warning in rbind.zoo(...) : column names differ
Hello; I am trying following but getting a warning message : Warning in rbind.zoo(...) : column names differ, no matter whatever I do. Also I do not want to specify column names manually, since I am just writing a wrapper function around getSymbols to get chunks of data from various sources - oanda, dividends etc. I tried giving col.names = T/F, header = T/F and skip = 1 but no help. I think
2007 Jan 30
2
Rbind for appending zoo objects
Hi R, y1 <- zoo(matrix(1:10, ncol = 2), 1:5) colnames(y1)=c("a","b") y2 <- zoo(matrix(rnorm(10), ncol = 2), 6:10) colnames(y2)=c("b","a") > y1 a b 1 1 6 2 2 7 3 3 8 4 4 9 5 5 10 > y2 b a 6 0.9070204 0.3527630 7 1.2405943 0.8275001 8 -0.1690653 -0.1724976 9 -0.6905223 -1.1127670 10
2008 Oct 19
1
zoo in ggplot2
library(zoo) d<-(structure(c(1.39981554315924, 0.89196314359498, 0.407816250252697, 0.823496839063978, 1.14429021220358, 1.23971035967413, 0.960868900583432, 0.927685306209829, 1.22072345292821, 0.249842897450642, 1.00879641624694, 0.925372139878243, 0.317259909172362, 0.382677149697482), index = structure(c(11808, 11869, 11961, 11992, 12084, 12173, 12265, 12418, 12600, 12631, 12753, 12996,
2008 Nov 16
1
inconsistency between timeSeries and zoo causing a problem with rbind
Dear R Users and maintainers of packages zoo and timeSeries, I believe there is a recently introduced inconsistency between timeSeries and zoo which is causing a problem with rbind. I had previously reported that I was having problems with rbind in the following code: library(zoo) foo<-zoo(1,order.by=as.Date("2007-10-09")) bar<-zoo(2,order.by=as.Date("2007-10-10"))
2011 Feb 09
1
merge, rbind, merge.zoo? adding new rows to existing data.frame
Hi all, I'm trying to add updated data to an existing time series where an overlap exists. I need to give priority to the update data. My script runs every morning to collect data the updated data. There are quite often varied lengths, so once off solutions identifying rows to solve this example won't work. I've experimented with merge, rbind, merge.zoo, but to no avail. An example
2008 Jan 08
1
Error with rbind and zoo
Hi all: I have a directory of files as in -------------> bunchafiles <- list.files(path="/data/2.3/2006", pattern="returns", full.names=T,recursive=T) .... Each file is a bunch of returns for a particular date (unique). There are like 252 files or so. With a custom function myread (below), I define a vector ----- res <-
2009 Jun 11
2
How to force R to print 2 decimal places in column of a data.frame?
How to force R to print 2 decimal places in column of a data.frame? I tried to do so: x = inp(format(rounf(inp$Tamanho, 2), nsmall = 2),) where "INP" is data.frame and "Size" is the name of column. But has error: Error in eval.with.vis(expr, envir, enclos) : could not find function "inp" Lesandro Veja quais s?o os assuntos do momento no Yahoo! +Buscados
2020 May 12
4
CentOS7 and NFS
Hi, I need some help with NFSv4 setup/tuning. I have a dedicated nfs server (2 x E5-2620? 8cores/16 threads each, 64GB RAM, 1x10Gb ethernet and 16x 8TB HDD) used by two servers and a small cluster (400 cores). All the servers are running CentOS 7, the cluster is running CentOS6. Time to time on the server I get: ?kernel: NFSD: client xxx.xxx.xxx.xxx testing state ID with incorrect
2008 Jan 24
1
Sliding Window Time Series Analysis - hourly rainfall
I have a time series of rainfall in a dataframe. I would like to be able to aggregate this using a sliding window approach- i.e. a new 24 hourly total is calculated for each hours rainfall. I'm struggling to understand how this might be achieved - currently I've tried looping a sum function to re-calculate a new total at every stage of the loop. for (inp[[9]] in
2014 Jan 06
1
Re: [PATCH 2/2] lib: utf16: Fix const-correctness issues in _hivex_recode function.
On Tuesday 31 December 2013 14:27:11 Richard W.M. Jones wrote: > This patch assumes that iconv doesn't actually modify the > input buffer, even though it is declared as char *. > --- > [...] > @@ -51,10 +51,11 @@ _hivex_recode (char *input_encoding, const char > *input, size_t input_len, errno = err; > return NULL; > } > - char *inp = input; > + const
2020 May 12
2
CentOS7 and NFS
Le 12/05/2020 ? 16:10, James Pearson a ?crit?: > Patrick B?gou wrote: >> >> Hi, >> >> I need some help with NFSv4 setup/tuning. I have a dedicated nfs server >> (2 x E5-2620? 8cores/16 threads each, 64GB RAM, 1x10Gb ethernet and 16x >> 8TB HDD) used by two servers and a small cluster (400 cores). All the >> servers are running CentOS 7, the cluster is
2011 Sep 09
3
Read a list of files into named R data.frames
I have a collection of .csv files in a directory, and want to read them into R data.frames whose names are the same as the file names, without the .csv extension e.g., from > (files <- list.files(pattern="*.csv")) [1] "Allstar.csv" "AllstarFull.csv" [3] "Appearances.csv" "AwardsManagers.csv" [5]
2013 Jun 18
1
deSolve question
Dear All wonder if you could provide some insights on the following: currently I have this code which produces the expected results: require(deSolve) pars <- list(k = 0.08,v=15) intimes <- c(0,0.5,12) input <- c(800,0,0) forc <- approxfun(intimes, input, method="constant", rule=2) derivs <- function(t, state, pars) { inp <- forc(t) dy1 <- - pars$k * state[1]
2020 Jul 09
1
CentOS7 and NFS
Hi Orion, no, I still have this problem. I delay working on it as I the latest updates have not been installed on the server and on the client. I'll work again on this problem as soon as possible. Thanks Charles for your detailed information on how to track this problem. I'll check all these metrics. I have several clients for this nfs server and the problem seems only to occur from the
2020 May 13
2
CentOS7 and NFS
Le 13/05/2020 ? 07:32, Simon Matter via CentOS a ?crit?: >> Le 12/05/2020 ? 16:10, James Pearson a ?crit?: >>> Patrick B?gou wrote: >>>> Hi, >>>> >>>> I need some help with NFSv4 setup/tuning. I have a dedicated nfs server >>>> (2 x E5-2620? 8cores/16 threads each, 64GB RAM, 1x10Gb ethernet and 16x >>>> 8TB HDD) used by two
2010 Apr 25
1
Manipulating text files
Dear R Community, I am trying to optimize a water quality model that I am using. Based on conversations with others more familiar with what I am doing I plan to implement DEOptim to do this. The water quality model is interfaced through a GUI. I have the input file necessary to alter parameters and run the model as a text file. To do the optimization I have figured out the general procedure
2020 Jun 01
3
CentOS7 and NFS
Le 13/05/2020 ? 02:13, Orion Poplawski a ?crit?: > On 5/12/20 2:46 AM, Patrick B?gou wrote: >> Hi, >> >> I need some help with NFSv4 setup/tuning. I have a dedicated nfs server >> (2 x E5-2620? 8cores/16 threads each, 64GB RAM, 1x10Gb ethernet and 16x >> 8TB HDD) used by two servers and a small cluster (400 cores). All the >> servers are running CentOS 7, the
2010 Jul 31
1
Lags and Differences of zoo Objects
Hi, I'm struggling to understand the documentation. ?lag.zoo x - a "zoo" object. k, lag - the number of lags (in units of observations). Note the sign of k behaves as in lag. differences - an integer indicating the order of the difference. What does the above line actually mean? I've tried a few settings on sample data but can't figure out what it is doing. x <-
2008 Mar 02
1
question on lag.zoo
Hi Guys, I'm using zoo package now. I found lag is not doing what I assumed. > x <- zoo(11:21) > z <- zoo(1:10, yearqtr(seq(1959.25, 1961.5, by = 0.25)), frequency = 4) > x 1 2 3 4 5 6 7 8 9 10 11 11 12 13 14 15 16 17 18 19 20 21 > lag(x) 1 2 3 4 5 6 7 8 9 10 12 13 14 15 16 17 18 19 20 21 > z 1959 Q2 1959 Q3 1959 Q4 1960 Q1 1960 Q2 1960 Q3 1960 Q4