Displaying 11 results from an estimated 11 matches for "l_pli".
Did you mean:
_pli
2009 Sep 28
4
How to assess object names within a function in lapply or l_ply?
Dear All,
to produce output of several columns of a data frame, I tried to use
lapply and also l_ply. In both cases, I would like to print a header
line containing also the name of the respective column in the data frame.
For example, I would like the following
lapply(data.frame(a=1:3, b=2:4), function(x) print(deparse(substitute(x))))
to produce:
[1] "a"
[1] "b"
and
2010 Jul 07
1
problems with write.table, involving loops & paste statement
Hi!
I want to write portions of my data (3573 columns at a time) to twenty
folders I have available titled "A_1" to "A_20" such that the first 3573
columns will go to folder A_1, next 3573 to folder A_2 and so on.
This code below ensures that the data is written into all 20 folders, but
only the last iteration of the loop (last 3573 columns) is being written
into ALL of the
2011 Jun 30
2
Saving fExtremes estimates and k-block return level with confidence intervals.
I am estimating a large model by groups. How do you save the results and?returns
the associated quantiles?
For this example I need a data frame
n?? ?xi??????? mu????????beta
1?? 0.1033614? 2.5389580 0.9092611
2? ?0.3401922? 0.5192882 1.5290615
3?? 0.5130798? 0.5668308 1.2105666
I also want to apply gevrlevelPlot() for each "n" or group.
?
#Example
n <- c(1, 1, 1, 1, 1, 1, 2, 2, 2,
2009 Apr 29
2
help converting for loop to vector operation
Dear List,
I have a wrapper function that draws a graph that I'd like to use in a vector-like manner. The for-loop version I currently use is below.
library(ggplot2)
data(economics)
h <- 600
w <- 800
#----------------------------------------------------------
draw_metric_by_date <- function( df, i, smooth=FALSE, BASEPATH ) {
mlabel <- names(df)[i]
qmetric
2008 Sep 30
0
New package: plyr
plyr is a set of tools that solves a common set of problems: you need
to break a big problem down into manageable pieces, operate on each
pieces and then put all the pieces back together. It's already
possible to do this with split and the apply functions, but plyr just
makes it all a bit easier with:
* consistent names, arguments and outputs
* input from and output to data.frames,
2008 Sep 30
0
New package: plyr
plyr is a set of tools that solves a common set of problems: you need
to break a big problem down into manageable pieces, operate on each
pieces and then put all the pieces back together. It's already
possible to do this with split and the apply functions, but plyr just
makes it all a bit easier with:
* consistent names, arguments and outputs
* input from and output to data.frames,
2009 Nov 19
4
Is there an variant of apply() that does not return anything?
There are a few version of apply() (e.g., lapply(), sapply()). I'm
wondering if there is one that does not return anything but just
silently apply a function to the list argument.
For example, the plot function is applied to each element in 'alist'.
It is redundant to return anything from apply.
apply(alist,function(x){ plot each element of alist})
2010 May 31
4
Fancy Page layout
Hi,
Working on a report that is going to have a large number of graphs and
summaries. We have 80 "groups" with 20 variables each.
Ideally, I'd like to produce ONE page for each group. It would have two
columns of 10 graphs and then the 5 number summary of the variables at
the bottom.
So, perhaps the top 2/3 of the page has the graphs and the bottom third
has 20 rows of data
2009 Sep 28
4
Running an ANOVA with a BY
I have a simple 1 way anova coded like
summary(ANOVA1way <- aov(Value ~ WellID, data = welldata))
How can I use the BY function to do this ANOVA for each group using another
variable in the dataset?? I tried coding it like this, but it doesn't seem
to work.
summary(ANOVA1way <- by(welldata, Analyte, function(x) aov(Value ~ WellID,
data = welldata)))
In SAS I would code it like this:
2010 Jun 01
4
Plot multiple columns
I'm running a long MCMC chain that is generating samples for 22 variables.
I have each run of the chain as a row in a matrix.
So: Chain[,1] is the column with all the samples for variable one.
Chain[,2] is the column with all the samples for variable 2, etc.
I'd like to fit all 22 on a single page to print a nice summary. It is
OK if the graphs are small, I just need to show the
2010 Dec 29
5
linear regression for grouped data
Hi,
I have been examining large data and need to do simple linear regression
with the data which is grouped based on the values of a particular
attribute. For instance, consider three columns : ID, x, y, and I need to
regress x on y for each distinct value of ID. Specifically, for the set of
data corresponding to each of the 4 values of ID (76,111,121,168) in the
below data, I should invoke