similar to: function returns R object with name based on input

Displaying 20 results from an estimated 6000 matches similar to: "function returns R object with name based on input"

2008 Nov 04
1
perform Kruskal-Wallis test without using the built-in command in R
Hi, again i am stuck in my presentation, and i have never learn R before in my life but need this to be done, so please help me out for a favour: http://www.nabble.com/file/p20333155/kew.dat kew.dat run this in R and these comes up: Month Year Rain 1 Jan 1900 74.400000 2 Feb 1900 80.500000 3 Mar 1900 23.600000 4 Apr 1900 23.600000 5 May 1900 25.100000 6
2013 Mar 13
2
merge datas
Hello all! I have a problem with R. I try to merge data like this: structure(c(2.1785, 1.868, 2.1855, 2.5175, 2.025, 2.435, 1.809, 1.628, 1.327, 1.3485, 1.4335, 2.052, 2.2465, 2.151, 1.7945, 1.79, 1.6055, 1.616, 1.633, 1.665, 2.002, 2.152, 1.736, 1.7985, 1.9155, 1.7135, 1.548, 1.568, 1.713, 2.079, 1.875, 2.12, 2.072, 1.906, 1.4645, 1.3025, 1.407, 1.5445, 1.437, 1.463, 1.5235, 1.609, 1.738, 1.478,
2013 Mar 12
5
extract values
Hello all! I have a problem to extract values greater that for example 1820. I try this code: x[x[,1]>1820,]->x1 Please help me! Thank you! The data structure is: structure(c(2.576, 1.728, 3.434, 2.187, 1.928, 1.886, 1.2425, 1.23, 1.075, 1.1785, 1.186, 1.165, 1.732, 1.517, 1.4095, 1.074, 1.618, 1.677, 1.845, 1.594, 1.6655, 1.1605, 1.425, 1.099, 1.007, 1.1795, 1.3855, 1.4065, 1.138, 1.514,
2013 Apr 07
2
group data in classes
Hello all! I have a problem to group my data (years) in 10 years classes. For example for year year decade 1598 1590-1600 1599 1590-1600 1600 1590-1600 1601 1600-1610 --- my is like this> [1] 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 [16] 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 [31] 1628 1629 1630 1631 1632 1633
2013 Mar 29
1
problem with data
Hello all! I have a problem with my data in R. When I want to plot the following data, I have a problem with y scale. The maximum value is cc. 10 degrees and in R is about 100. I use this code: fasy<-read.table("gridd1.txt",sep="\t",dec=",",header=T,row.names=1) # here are the years: x <- as.numeric(rownames(fasy)) # extract a series that you want to plot: y
2010 Jan 11
3
interpolation
Dear R-users, I have a complex line by xy-values (ordered by z). And I would like to get interpolated y-values on the positions of x = 0:600. How do I get the correct points? x=c(790,790,790,790,790,786,783,778,778,766,763,761,761,761,715,628,521,350,160,134,134,129,108,101,93,111,161,249,288,243,139,45,7)
2013 Apr 08
2
How can I extract part of the data in a panel dataset?
Taking the Grunfeld data, which is built-in in R, for example, (1)How can I construct a dataset (or dataframe) that consists of the data of all firms in 1951? (2)How can I calculate the average capital in each form over the period 1951-1954? What I can imagine is to categorize the data by firm, and then select the data between 1951 and 1954 for each firm, but how can I do it? Thanks, Miao
2010 Sep 22
2
Unique subsetting question
Hi all, I'm looking at a large data set, and I'm interested in removing rows where only one variable is duplicated. Here's an example: > presidents Qtr1 Qtr2 Qtr3 Qtr4 1945 NA 87 82 75 1946 63 50 43 32 1947 35 60 54 55 1948 36 39 NA NA 1949 69 57 57 51 1950 45 37 46 39 1951 36 24 32 23 1952 25 32 NA 32 1953 59
2013 Apr 01
0
ggplot2 label problem
I have a problem to plot label (Year) only for significant values (in this case spoz and sneg). I use this code, but don't work with labels. library(ggplot2) ggplot(data1, aes(x = Year, y = value,fill=type,width=1))+ geom_bar(stat="identity",position="identity")+ scale_y_continuous(breaks = round(seq(-100, 100, by = 10),10))+ theme_bw() Thank you! the data used is:
2016 Jun 02
1
[PATCH -next 2/2] virtio_net: Read the advised MTU
Hi, [auto build test ERROR on next-20160602] url: https://github.com/0day-ci/linux/commits/Aaron-Conole/virtio-net-Advised-MTU-feature/20160603-000714 config: i386-allmodconfig (attached as .config) compiler: gcc-6 (Debian 6.1.1-1) 6.1.1 20160430 reproduce: # save the attached .config to linux build tree make ARCH=i386 Note: the
2016 Jun 02
1
[PATCH -next 2/2] virtio_net: Read the advised MTU
Hi, [auto build test ERROR on next-20160602] url: https://github.com/0day-ci/linux/commits/Aaron-Conole/virtio-net-Advised-MTU-feature/20160603-000714 config: i386-allmodconfig (attached as .config) compiler: gcc-6 (Debian 6.1.1-1) 6.1.1 20160430 reproduce: # save the attached .config to linux build tree make ARCH=i386 Note: the
2007 Sep 27
1
add a row to a data frame
Hi everybody, I've a data.frame "d" like this: 0 2 4 6 8 10 12 14 16 X0 X2 X4 1945 350 NA NA NA NA NA NA NA NA 0.3848451 0.0000000 0.0000000 1946 408 NA NA NA NA NA NA NA NA 1.4202009 0.0000000 0.0000000 1947 511 NA NA NA NA NA NA NA NA 3.2540522 0.0000000 0.0000000 1948 342 215 NA NA NA NA NA NA
2016 Mar 12
2
Regression in strptime
On 3/12/16 12:33 AM, peter dalgaard wrote: >> On 12 Mar 2016, at 00:05 , Mick Jordan <mick.jordan at oracle.com> wrote: >> >> This is definitely obscure but we had a unit test that called .Internal(strptime, "1942/01/01", %Y/%m/%d") with timezone (TZ) set to CET. > Umm, that doesn't even parse. And fixing the typo, it doesn't run: > >>
2008 Sep 10
2
Woring message in as.yearmon()
I have following dataset: > res [,1] [,2] [,3] [1,] 1946 4 1.27 [2,] 1946 5 1.27 [3,] 1946 6 1.27 [4,] 1946 7 1.27 [5,] 1946 8 1.52 [6,] 1946 9 1.52 [7,] 1946 10 1.52 [8,] 1946 11 1.52 [9,] 1946 12 1.62 [10,] 1947 1 1.62 [11,] 1947 2 1.62 [12,] 1947 3 1.62 [13,] 1947 4 1.87 [14,] 1947 5 1.87 [15,] 1947 6 1.87 Now I write following code
2010 Mar 09
3
sorting data whilst ignoring NA's
Hello, I am very new to R and have hit my first main problem that I hope someone can easily resolve. I have some data that looks like this (there are 20,000 rows): > qdata day month year flow [1,] 2 10 1945 NA [2,] 3 10 1945 NA [3,] 4 10 1945 NA [4,] 5 10 1945 NA [5,] 6 10 1945 2.973 [6,] 7 10 1945 NA
2012 Jan 18
0
Time series questions
Hi, I am trying to teach myself some time series analysis. I have some time series data on GDP, quarterly, from 1947 to 2011. colnames are "Year" "Quarter" "GDP" and "GDP.deflator" The first problem I have is that 4th quarter 2010 is missing--not even NA, there is no record for Year=2010 and Quarter =4, so instead of 260 rows, I only have 259. To solve
2016 Mar 12
0
Regression in strptime
OK, .Internal is not necessary to reproduce oddity in this area. I also see things like (notice 1980) > strptime(paste0(sample(1900:1999,80,replace=TRUE),"/01/01"), "%Y/%m/%d", tz="CET") [1] "1942-01-01 CEST" "1902-01-01 CET" "1956-01-01 CET" "1972-01-01 CET" [5] "1962-01-01 CET" "1900-01-01 CET"
2003 Nov 04
1
hclust doesn't return merge details [Solved]
Thanks to Andy and Thomas, Reading help(hclust) more carefully would have done it but sometimes you do not see the wood for the trees... So hc$merge does exactly what I want. I have never been aware of the command str to get the structure of an R-object. It seems pretty useful to me. Thanks, Arne > -----Original Message----- > From: Liaw, Andy [mailto:andy_liaw at merck.com] >
2011 May 30
0
gls and phi1 >1 (phi larger than one)
Dear all, I am stuck with a problem that might be trivial for most of you (and therefore is a bit embarrassing for me...): I want to calculate a generalized least squares regression using two time series (Y depending on X) with an autoregressive correlation structure of order two (the data along time are given below). I use 'gls' from package 'nlme': Calib.gls <- gls(Y~X,
2002 May 31
2
error in seq.POSIXt?
I am trying to extract only the winters (defined to be 01-Dec through 28-Feb) of daily data from 1948-2002. There are 90 days in each winter season. I wrote the following code to gather the winter dates into a single vector: DJF <- NULL for(year in 1949:1999) { temp.begin <- strptime(paste("01/12", year-1, sep="/"), "%d/%m/%Y") temp.end <-