similar to: How to create time series objects combining two vectors

Displaying 20 results from an estimated 1000 matches similar to: "How to create time series objects combining two vectors"

2010 Feb 15
4
Separating columns, and sorting by rows
Dear anyone who knows more about R than me (so everyone). I have been bashing my head on the keyboard all day trying to do something with my table. I have some data, like so: yyyy-mm Rainfall(mm) 1 1977-02 17.4 2 1977-03 34.0 3 1977-04 26.2 4 1977-05 42.6 5 1977-06 58.6 6 1977-07 23.2 7 1977-08 26.8 8 1977-09 48.4 9
2007 Jul 25
1
how to use "replace" for efficiency
Hi I think I have been struggling to use replace correctly, I usually work my way around this using a loop, but I think this is in fact inefficient. I have a dataset with runoff from three plots and associated rainfall. However either the datarecording was sloppy, or the rainfall very patchy. So I am trying to remove data from my dataset for which the runoff is larger than the rainfall on the
2002 Apr 23
1
column-plot of rainfall data
Hello, I have some daily rainfall data from rain gages. E.g.: date p1 p2 p3 20/04/2002 10.2 8.6 6.3 21/04/2002 0.4 1.6 1.4 22/04/2002 0.2 0.0 0.4 23/04/2002 5.2 1.0 0.2 I'd like to plot them in a column plot by day, to be able to compare them. I made an example in exell, that I attached, but can't find out how to do it in R. The data vector is a POSIXct. Thanks, Wouter
2010 May 24
2
sum of certain length
Hi r-users,   I have this data below.  I would like to obtain the weekly rainfall sum.  That is I would like to find sum for day 1 to day 7, day 8 - day15, and so on.    year month day rain 1  1922     1   1  0.0 2  1922     1   2  0.0 3  1922     1   3  0.0 4  1922     1   4  0.0 5  1922     1   5  0.0 6  1922     1   6  0.0 7  1922     1   7  0.0 8  1922     1   8  6.6 9  1922     1   9  1.5 10
2010 Jul 30
2
Need a help to plot bar for time series Rain data
Hey Guys, I am quite new to R, am trying to plot a bar plot for my monthly rainfall data from 1920 to 1990. For every year I have the data from January to December. I have created this code: data<-read.table("C://R//Data//Rain.txt", header=TRUE) data<-data[,2:13] Rdata<-data[1,] for(i in 2:79){Rdata<-c(Rdata,data[i,])} times<-ts(Rdata,start=1920,frequency=12)
2011 Feb 04
1
Easy help with plots, font size
I am trying to make some plots for a poster. Each one needs to be 6 inches by inches. Right now the fonts are too small and the plots don't read well on my poster. I am pretty much an R newbie and I can't figure out how to change the fonts. It would also be nice to know how to specify the size of the plot and maybe how to save the plots as jpeg files. Any help would be much appreciated! I
2003 Oct 22
2
High frequency time-series
Having to collect hourly electricity loads and quarter-of-an-hour electricity production data for some years I think that the tidiest way of doing it is to resort to ts but I don't know how to define such a frequency starting from a set date. Leafing through r-help mail archives I've found this *ALMOST* satisfactory message: ==========================================================
2008 Jun 05
1
choosing an appropriate linear model
I am trying to model the observed leaching of wood preservative chemicals from treated wood during an outdoor experiment where leaching is caused by rainfall events. For each rainfall event, the amount of rainfall was recorded as well as the amount of preservative chemical leached. A number of climatic variables were measured, but the most important is the amount of rainfall. I have tried a
2013 Apr 14
1
Model selection: On the use of the coefficient determination(R2) versus the frequenstist (AIC) and Bayesian (AIC) approaches
Dear all, I'm modeling growth curve of some ecosystems with respect to their rainfall-productivity relationship using a simple linear regression (ANPP(t)=a+b*Rain(t)) and a modified version of the Brody Model ANPP(t)=a*(1-exp(-b*rain(t))) I would like to know why the "best model" is function of the criteria that I use (maximizing the fit using R2 or testing the Null hypothesis with
2007 Oct 14
0
repeated measures - aov, lme, lmer - help
Dear all, I'm not very sure on the use of repeated measures in R, so some advice would be very appreciate. Here is a simple example similar to my real problem (R 2.6.0 for windows): Lets supose I have annual tree production measured in 9 trees during 3 years; the 9 trees are located in 3 different mountains (sites), and each tree receive different annual rainfall (different locations). I would
2011 Sep 04
1
combining rows
First time using R and have so many basic questions. The problem that I have confronted is combining rows. I have a data frame that contains daily rain falls from 60 to 80. There are 27 columns which are Year,month, day, and record in hours. I am trying to combine the 4th column to the 27th to get daily rain fall data. rowSums() works in the case of merging all rows but in my case, I need to
2011 May 20
1
Multiple count if style "queries"
Dear List, I am looking to calculate two things from my data frame and was after some advice. For the example below i want to know. 1. How many unique Orders/Families and Genera there are per eco-name 2. How many incidences are there for each Order/Family and Genus there are per eco-region I have 650 econame. I.e for Biak-Numfoor rain forests there are 2 orders, 2 families and two genera.
2011 Aug 22
3
Multiple regression in R - unstandardised coefficients are a different sign to standardised coefficients, is this correct?
Hello, I have a statistical problem that I am using R for, but I am not making sense of the results. I am trying to use multiple regression to explore which variables (weather conditions) have the greater effect on a local atmospheric variable. The data is taken from a database that has 20391 data points (Z1). A simplified version of the data I'm looking at is given below, but I have a
2009 Mar 31
3
labeling panels in lattice plots
I am using windows XP with R 2.8.1 I am generating a lattice plot of annual rain patterns using the following function: > xyplot(rain.stats$min+ rain.stats$max + rain.stats$ave ~ rain.stats$month |rain.stats$year, lty = 1, data = rain.stats, type = c("l","l", "l"), col = c("red", "blue", "green"), distribute.type =
2008 Jul 08
0
Multiple Plots and y Axis Labels
Hi, I'm using the mfrow parameter in par() to plot several timeseries with a common time x axis as a sequence of plots one below the other. I reduced the top and bottom margins to zero to get a very nice looking plot but sometimes the labels on the y axes from one plot overlap with the y axis labels on the plot above or below. Any ideas how I can prevent this without losing the look of the
2006 Jul 02
1
Calculation of lags
Hi, If I have the follow situation: A dependent variable (i.e. number of insects) that is affected by an independent variable (i.e. rain). The problem is that the measure of rain affect the population in other moment. So there exit a lag between the rain and the number of insects. Exist in R any tool to find what is this lag? Explain better. Suppose that I have a linear relationship
2004 Aug 18
1
Fwd: strptime() problem? - Resolved
Hi Gabor and everybody; Thanks Gabor, with the alternative step you've told me the problem is resolved. Comparing the two procedures: Extract from the source 'character' data: > rain$ts[2039:2046] [1] "25/03/2000 22:00:00 UTC" "25/03/2000 23:00:00 UTC" [3] "26/03/2000 00:00:00 UTC" "26/03/2000 01:00:00 UTC" [5] "26/03/2000 02:00:00
2002 Apr 26
3
different data series on one graph
Hello, I'm looking for a way to plot different data series on one graph. I have a series of hourly rainfall and quarterly flow measurements (i.e. 4 times an hour) of a catchment. The rainfall should be plotted in bars, the flow as a line. Both on the same X axe (time) but with different Y axes. The problem is the plot() function does not support add=TRUE... Furthermore I'm not sure
2006 Jun 27
2
distribution of daily rainfall values in binned categories
Hi, I'm a newbie in using R and I would like to have a few clues as to how I could compute and plot a distribution of daily rainfall intensity in different categories. I have daily values (mm/day) for several years and I need to show the frequency of 0-1, 1-2.5, 2.5-5, 5-10, 10-20, 20+ mm/day. Can this be done easily? Thanks, Etienne
2017 Nov 23
0
How to produce rainfall maps
Thank you Sarah and Mike for your explanations. My final objective is to produce maps (png image or any kind of extension I can import in LaTeX) where rainfall data are interpolated, using the Inverse Distance method or Kriging. My input file (pointfile.csv in the reported example) reports the station code, lat and long of the meteorological station and the rainfall value (which might be the