Displaying 20 results from an estimated 5000 matches similar to: "plot and lm (2)"
2006 Aug 07
2
finding x values to meet a y
Hi,
I'd like to find which values of x will give me a y.
In other words, in the example of a gaussian curve, I want to find the values of
x that will give me a density, let's say, of 0.02.
curve(((1/(sqrt(2*pi)*10))*exp(-((x-50)^2)/(2*10^2))),xlim=c(0,100))
Thanks for any help,
Antonio Olinto
-------------------------------------------------
WebMail Bignet - O seu provedor do
2001 Sep 07
3
fitting models with gnls
Dear R-list members,
Some months ago I wrote a message on the usage of gnls (nlme library) and here I come again.
Let me give an example:
I have a 10 year length-at-age data set of 10 fishes (see growth.dat at the end of this message) and I want to fit a von Bertalanffy growth model, Li= Linf*(1-exp(-k*(ti-t0))) where Li = length at age i, Linf= asymptotic length, k= curvature parameter, ti=
2001 Sep 11
2
data frames
Dear R-list members
Here goes a question on data frames:
I want to create a new data frame excluding some records
(rows) from an existing one.
Considering the data frame "fish.dat" at the end of this
message, I can make a boxplot(Ring~Radius) and identify the
points at rows 11 and 25 as outliers.
With the command fish.dat[c(11, 25),] I can identify which
fishes are related to
2001 Sep 25
2
max-min plot
Hello R-list members,
I’m trying to make a min-avg-max plot (like a boxplot, without
box and outliers, i.e., for each class of "x" a vertical line
indicating the range (max-min) and an horizontal line or point
indicating the mean) with data like:
Year Avg Min Max
98 10 7 13
99 12 10 15
01 11 6 14
Which command should be used?
Many thanks,
Antonio Olinto
2004 May 19
3
greek letters in plots
Hi,
I want to write in x axis label "fitted value of lambda" (lambda in greek
letter).
xlab=expression(lambda) gives the "lambda", I tryed things like xlab=paste
("fitted value of ", expression(lambda)) but I didn't get the greek letter.
Thanks in advance for any hint.
Antonio Olinto
-------------------------------------------------
WebMail Bignet - O seu
2001 Nov 09
2
ks.test
Dear R-List members,
I want to check if a set of measurements follows better a
gamma or a lognormal distribution (see data below).
Using shapiro.test I can test for normality (shapiro.test(log
(Lt)).
To test for gamma (and normal) distribution I would use
ks.test but I need to specify its shape and scale. How should
I calculate these values in R?
I tried
> Lt.fit <- glm(Lt ~ 1,
1999 Dec 26
3
coredump with plot(x,y,pch="+",cex=2.2) (PR#389)
Core dumped when plot() is used with pch="c" & cex > 2, e.g.,
plot(1,1, pch="+", cex=2.2)
Thank you and best wishes for 2000!
Rashid Nassar
--please do not edit the information below--
Version:
platform = i586-unknown-linux
arch = i586
os = linux
system = i586, linux
status =
major = 0
minor = 90.1
year = 1999
month = December
day = 15
language = R
2000 Jul 10
3
help page typos (PR#599)
A couple of help page typos that I came across:
1.
help(sample)
Arguments:
x: Either a (numeric, complex, character or logical) vector of
more than one elements from which to choose, or a positive
^
[element]
2.
help(delay)
Description:
`delay' creates a promise to evaluate the given expression in the
2004 Dec 06
1
using subset
Hi,
I have doubts in using subset command. I have a list of, lets say, 15 species
and I want to make a subset with only 2 of them. I??m the command
data2 <- subset(data1, species=="sp1"|species=="sp2")
Nevertheless, when I ask for the summary (summary(data2)) the others species
names still apearing. Also I tried
data2<-data1(data1$species %in%
2004 Sep 16
4
FW: How do I insert a newline in my title in a plot?
yes I have tries, and nothing. It just shows the strings with the slashn,
just like i typed it.
-----Original Message-----
From: Rashid Nassar [mailto:rnassar at duke.edu]
Sent: ÐÝì?ôç, 16 Óå?ôåìâñßïõ 2004 15:44
To: Christos Rodopoulos
Subject: Re: [R] How do I insert a newline in my title in a plot?
Have you not tried what you have already suggested:
title("this is a title\nIn 2
1999 Apr 07
2
Bug list summary (automatic post)
=================================================
This is an automated summary of the status of the R-bugs
repository.
Note that this may be neither complete nor perfectly
correct at any given instance: Not all bugs are reported,
and some reported bugs may have been fixed, but the
repository not yet updated.
Some bug fixes are difficult to verify because they pertain
to specific hardware or
2002 Jan 19
2
comma as decimal separator in plots
Hi,
Some time ago I asked about how to use comma as decimal separator in plots
and Mr. Paul Murrell wrote:
-------
You could try something with axis() and chartr(), like ...
par(mfrow=c(2,1))
plot(1:10/11, rep(1, 10), main="Standard X-Axis")
plot(1:10/11, rep(1, 10), main="Customised X-Axis", axes=F)
axis(1, at=pretty(1:10/11),
1999 Nov 10
2
R.bug.report (PR#315)
Again I would like to express my deepest appreciation to all those
working so selflessly on the development of R for us all to use it
freely (and it is such a joy to use!)
Rashid Nassar
== Possible bug:
1.
boxplot()
This is an old behavior that I had reported before, but as it is still
there, it may not ba a bug (although it looks like one to me). "qfcut"
is numeric, "st"
2001 Mar 28
4
fitting growth curves
Dear R-list members,
Cynthia M. Jones wrote a paper (Fitting growth curves to retrospective
size-at-age data, Fisheries Research 46(2000):123-129; abstract at
http://www.elsevier.nl/gej-ng/10/19/44/70/24/37/abstract.html)where the
SAS procedure MIXED, Macro NLINMIX (Littell et. al., 1996)was used to
estimate the von Bertalanffy growth function parameters assuming that
data from the same fish are
2002 May 01
0
coefficient of determination on a nls regression
Antonio,
For linear regression we have the following identity
total SS = regression SS + residual SS (*)
where total SS is the sum of squares of observations around their mean,
i.e.
total SS = (n-1)*var(y)
and residual SS is given by the deviance function.
R-squared is defined as
R^2 = regression SS/ total SS = 1 - residual SS/total SS.
You can use this last formula
2002 Oct 30
0
extracting Std. Error value from lm/nls
?summary.lm says, under the "Value" section,
coefficients: a p x 4 matrix with columns for the estimated coefficient,
its standard error, t-statistic and corresponding (two-
sided) p-value.
so try summary(fit.lm)$coefficients[,1:2] to get the coefficients and their
SEs.
For nls, it takes a bit more digging, as the documentation is a bit sparse.
Something
2000 Nov 05
3
glm
Hi to all,
So I'm also a new user. I downloaded the program last week and I think it's great. Thanks to those who have developed R.
I have a special interest in GLM as a tool to describe fisheries and its variables and I'm just begging to study it.
As I could understand there's two types of GLM sun of squares: in "type I" the factors are added in sequence and
2012 Dec 04
4
partial analisys of a time series
Dear list members
I want to analyze separately the months of a time series. In other words, I
want to plot and fit models for each month separately.
Taking the example of
http://a-little-book-of-r-for-time-series.readthedocs.org/en/latest/src/timeseries.html
births <- scan("http://robjhyndman.com/tsdldata/data/nybirths.dat")
birthstimeseries <- ts(births, frequency=12,
2000 Mar 13
3
problem with plot(...., xlim=c(5,0)) (PR#480)
plot(1:4,1:4,xlim=c(5,0),ylim=c(5,0))
shows axis labels as:
| | | | | |
0
rather than
| | | | | |
5 4 3 2 1 0
as I believe it used to do in some earlier version.
Thank you for R.
Rashid Nassar
--please do not edit the information below--
Version:
platform = i586-unknown-linux
arch = i586
2004 Apr 25
2
nonparametric multiple sample comparison
Hello all,
Here goes one of my first functions.
I want to make a nonparametric multiple sample comparison with unequal sample
sizes (see Zar?s Biostatistical Analysis, 3rd. Ed., pg. 201 Example 10.11, pg.
288 Example 11.10). In the real world, I want to compare samples of fish
length captured with different fishing gears.
After using the Kruskal-Wallis test I want to check the differences