Jim,
I read the code - strwidth(). is the function i needed.
Geoff.
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, m
Thanks Jim. I see you maintain the package. What r primitive do those
functions use to do font metrics so that the margin can adjusted?
Geoff.
On 11/03/14 06:27, Jim Lemon wrote:
On 03/10/2014 10:34 PM, Geoffrey wrote:
My barplot has nicely left justified horizontal labels, the names of
Hello, I am having trouble with the output from the strucchange package for
a dummy variable regression. Why do I still get an intercept term in the
output of lm03, below?
library(lmtest)
library(strucchange)
data(GermanM1)
#regular dummy regression with intercept
lm01 <- lm(m ~ as.factor(seaso
My barplot has nicely left justified horizontal labels, the names of
people. Written using text() . I use par("user")[1] - OFFSET to get the
placed nicely.
Now of course if i manually rescale/zoom the plot the labels get redrawn
at the 'wrong' location, including off the left of the plot.
I
es_string(y=n,colour=n))
}
return(g)
}
A.K.
On Monday, December 30, 2013 7:49 PM, Geoffrey
wrote:
I am trying add geom_line's using a loop but the nature of unevaluated
parameters is causing me problems.
This code works:
ex <- function() {
d <- data.frame(x=1:5,a=1:5,b=2:6,c=3:7)
I am trying add geom_line's using a loop but the nature of unevaluated
parameters is causing me problems.
This code works:
ex <- function() {
d <- data.frame(x=1:5,a=1:5,b=2:6,c=3:7)
g <- ggplot(d, aes(x))
g <- g +
geom_line(aes(y=a,colour=a)) +
geom_line(aes(y=b,colour=b)) +
g
Dear Friends, I am looking for an R version of the structural break test in
Andrews (2003). The excellent strucchange package does not include this
test (yet?). Is this test available in another package? If not, might
there already be a function written to do this test? Thank you very much.
Ci
Can anyone please tell me how to get the r-squared output from a piecewise
(segmented) regression using the strucchange package? Here is the R code I
have tried thus far.
library(lmtest)
library(strucchange)
data <- ts(c(rnorm(30), runif(30)), frequency = 12, start = c(2005, 01))
bpts <- breakp
Engineer (Solar/BatteriesO.O#. #.O#. with
/Software/Embedded Controllers) .OO#. .OO#. rocks...1k
---
Sent from my phone. Please excuse my brevity.
Geoffrey wrote:
My macro doesn't
My macro doesn't work for bwplot. But is working elsewhere.
What changes should i make to fix my macro.
Thanks.
The complete code sample is:
library(gtools)
library(lattice)
pic <- defmacro(fn, plotfunc, expr={png(filename=fn); plotfunc; dev.off()})
# this one fails.
pic("bw.png", {bwplot(Speci
VCU faculty and non-profit Georgia R School offer 11-14 substantial (4-10
classes each) online courses using R on: Fundamentals; Graphics; Data
Manipulation; Data Mining; Multivariate Statistics; PLS Path Modeling;
Programming; Simulation; and more. Take until May 15, 2013 to complete as
many cours
Hello. The data.table package is very helpful in terms of speed. But I am
having trouble actually using the output from linear regression. Is there
any way to get the data.table output to be as pretty/useful as that from
the plyr package? Below is an example.
library('data.table');
library('pl
Hello, I would like to write a function that makes a grouping variable for
some panel data . The grouping variable is made conditional on the begin
year and the end year. Here is the code I have written so far.
name <- c(rep('Frank',5), rep('Tony',5), rep('Edward',5));
begin <- c(seq(1990,1994),
The Georgia R School (http://georgia-r-school.org) is a non-profit
educational organization. With faculty from Virginia Commonwealth
University, we are conducting live, interactive, synchronous month-long
online courses on PLS path modeling and R statistical software during
October and November. A
virginica", select = (1:4)));
but I am lazy AND I want all three to be plotted besides each other AND I
don't want to manually type the Species myself.
is there an easier way to do this probably yes...
If you want to help me out... would be deeply appreciated..
Kind regards,
Thank you for the email. The data is unbalanced, meaning that some days are
missing. So the sequence of days could be something like Tuesday,
Wednesday, Friday, Monday. The diff function would produce 1, 2, 3. But I
would like it to produce 1, 2, 1 since there is really only 1 day between
Frida
Hello, I have some unbalanced panel data that is measured on weekdays only
(i.e., excluding Saturday and Sunday). I would like to get the number of
days between dates such that the number of days between a Friday and a
Monday is 1 (and not 3). Here is some code to illustrate my problem:
library(
NEW SECTION BEGINS JUNE 1 (11AM-2PM ET) AND MAY 27 (6PM-9PM ET)
The non-profit organization Information Institute (
http://www.information-institute.org) is offering a live, interactive,
synchronous online course entitled Fundamentals of Using R. The registration
cost for the 14-hour, 5 week cou
EARLY REGISTRATION ENDS APRIL 22
The non-profit organization *Information Institute* (
http://www.information-institute.org) and faculty from Virginia Commonwealth
University (VCU) are offering a live, interactive, synchronous online course
entitled Fundamentals of Using R. The early registratio
Hello, I would like to take the mean of a column from a data frame and then
bind the mean back to the data frame. I can do this using the following
lines of code, but I am looking for a more elegant solution. Thank you very
much. Geoff
name <- c('Frank','Frank','Frank','Tony','Tony','Tony','Ed'
The Information Institute (http://www.information-institute.org), a
charitable, non-profit, educational and scientific organization, in
conjunction with faculty from Virginia Commonwealth University (VCU), is
offering live, interactive, synchronous online classes (one AM and one PM to
reach all tim
he Year-to-Year percentage change in
Score that accounts for the missing data?;
#Notice that Tony is missing data for the Year 2007 and Edward is missing
the Year 2005;
#Note as well that we will need to end up losing the Year 2005 in the
calculation;
--
Geoffrey Smith
Visiting Assistant Professo
a$group, myData$name),
mean);
#The raw output from the tapply function is fine, but I would;
#really like the output to look like this;
# class group name mean
# 0 ATom62.5
#0 BJane58.5
#1 AEnzo
Hello, does anyone know how to compute the following two normality tests
using R:
(1) the Kiefer-Salmon (1983) statistic, Economics Letters 11, p. 123-127
(2) the modified Shapiro-Wilk statistic?
Thank you very much. Geoff
[[alternative HTML version deleted]]
__
Hello, I am trying to update the mgcv package on my Linux box and I keep
getting an "Out of memory!" error. Does anyone know of a fix for this?
Below is a snippet of the message that I keep getting: Thank you. Geoff
** R
** inst
** preparing package for lazy loading
** help
*** installing help
Suppose my data looks like this:
Obs, Male, Female, Height
1, T, F, 66
2, F, T, 64
3, T, F, 59
4, T, F, 55
5, F, T, 62
6,
" the missing YEAR such that the end
result will be balanced and look like:
ID,YEAR,HEIGHT
Tom,2007,65
Tom,2008,66
Mary,2007,45
Mary,2008,50
Harry,2007,62
Harry,2008,62
James,2007,68
James,2008,NA
Jack,2007,70
Jack,2008,NA
Jordan,2007,NA
Jordan,2008,72
Thank you. Geoff
--
Geoffrey Smit
Dawn and
Clara? Thank you.
--
Geoffrey Smith
Visiting Assistant Professor
Department of Finance
W. P. Carey School of Business
Arizona State University
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
https
id Winsemius
Cc: Geoffrey William Heard; r-help@r-project.org
Subject: Re: [R] 'persp' query
David Winsemius wrote:
>
> On Oct 6, 2009, at 4:46 AM, Geoffrey William Heard wrote:
>
>> Hi All
>>
>> I'm creating some 3-D plots using the function 'pers
Hi All
I'm creating some 3-D plots using the function 'persp', and have a query
regarding the ability to make changes to the label of the z-axis.
There are two things I would like to do. First, the default setting places the
label a little close to the axis for my liking. Is there any way of
data points or leave out 1/k random years.
What do you think?
Thanks,
Geoffrey
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R
Greetings,
Is there a way to control the number of digits after the decimal from linear
regression output using the memisc package?
I have tried the following code, but it does not work:
fm <- lm(y ~ X)
mtable(fm, digits=9)
The default seems to be 3 digits after the decimal.
Also, is there a
Geoffrey Smith
Visiting Assistant Professor
Department of Finance
University of Illinois at Urbana-Champaign
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting
9 V10
0.037819506 0.021107303 0.039035427 0.002694224
Get the mean of each column.
Q3: Now the big question. I want to substract V1 from each element of
column 1, V2 from each element of column 2, ... How do I do this?
I ended up doing this, which is highly inefficient.
> z<- t(t(
34 matches
Mail list logo