Displaying 20 results from an estimated 2000 matches similar to: "Lotos 1-2-3 date to POSIXct"
2002 Jan 28
4
Type III Sums of Squares
I am trying to reproduce an analysis done in SAS from which Type III Sums of
squares are used. How can you get Type III sums of squares in an aov similar
to what SAS provides?
With best wishes and kind regards I am
Sincerely,
Corey A. Moffet
Instructor
Department of Range, Wildlife, and Fisheries Management
Mail Stop 2125
Texas Tech University
Lubbock, Texas 79409-2125
(806) 742-2843 Voice
2002 Apr 17
4
Problem w/ axis and distortion in a plotting function
I have a function for plotting soil texture that I am having a problem with.
The function is:
plot.psd <- function(sand, clay, ...) {
conv.ter <- function(x, y) {
x.con <- 100 - x - y*cos(1/3*pi)
y.con <- y*sin(1/3*pi)
data.frame(x=x.con, y=y.con)
}
plot(conv.ter(sand, clay), xlim = c(0,100), ylim = c(0,100*sin(1/3*pi)),
axes = FALSE, xlab="",
2002 May 28
2
histogramming dates
I'd like to make a plot showing frequency of an event. The data
is in a data from that includes Year, Month and Day (of month)
fields, so I created a Date with ISOdate(Year, Month, Day,
tz=''). I can plot frequencies for the year 2002 with
> thisyear <- Date[Year==2002]
> hist( thisyear, xaxt='n' )
> axis.POSIXct( 1, at=seq(min(thisyear), max(thisyear),
2002 May 21
1
I() fails on objects of class POSIXct (PR#1587)
Although the documentation is somewhat sketchy, I() can be used to create
objects of class AsIs:
> I("a")
[1] "a"
attr(,"class")
[1] "AsIs" "character"
> I(4)
[1] 4
attr(,"class")
[1] "AsIs" "numeric"
> I(4 + 0i)
[1] 4+0i
attr(,"class")
[1] "AsIs" "complex"
>
This
2004 Sep 22
5
block statistics with POSIX classes
I have a monthly price index series x, the related return series y = diff(log(x)) and a POSIXlt date-time variable dp. I would like to apply annual blocks to compute for example annual block maxima and mean of y.
When studying the POSIX classes, in the first stage of the learning curve, I computed the maximum drawdown of x:
> mdd <- maxdrawdown(x)
> max.dd <- mdd$maxdrawdown
> from
2004 Mar 05
3
as.POSIXct problem
Hi all,
I'm having difficulty converting a 'dates' object to a POSIXct object:
testDATES<-c(35947,35971,36004,36008,36053,36066)
testDATES<-chron(dates=testDATES, format = c(dates = "m/d/y"),
origin=c(month = 12, day = 30, year = 1899))
>[1] 06/01/98 06/25/98 07/28/98 08/01/98 09/15/98 09/28/98
> as.POSIXct(testDATES)
[1] NA NA NA NA NA NA
2002 Oct 04
2
spline bug ?
# Is this a bug or something I don't understand?
spline(date, stor, n=52, xmin=mind, xmax=maxd)
# gives length(x) of 53 ????, but y has the expected length of 52
# Shouldn't they be the same length? From help (spline):
# spline returns a list containing components x and y which give the
# ordinates where interpolation took place and the interpolated values
# xmin and xmax are inside
2002 Jan 10
4
Test if beta is different from something other than 0
Is there a function/package that will allow you to test the hypothesis beta1
= x in a
simple linear regression, where x is a constant? The AOV tests if beta1 in
different from
0 but what if I want to know if beta1 one is different from 1?
With best wishes and kind regards I am
Sincerely,
Corey A. Moffet
Instructor
Department of Range, Wildlife, and Fisheries Management
Mail Stop 2125
Texas
2003 Apr 30
2
ylab in plot.POSIXct
I am using R-1.7.0 and have some data which consist of one vector of
numbers and a second corresponding vector of dates belonging to the
POSIXct class. I would like to plot the numbers against the dates.
What is the best way to do this?
It almost works to just call `plot.' However if I do this while using
the `ylab' parameter I get a warning message:
parameter "ylab"
2003 Jul 26
1
bug plotting dates?
Hello R-experts!
I am using R Version 1.7.1 (2003-06-16) on a Debian Linux box and I
have discovered an odd result when plotting data involving dates. Please
try this minimal example:
a = seq(ISOdate(2000,1,1), ISOdate(2001,1,1), "months")
b = 1:13
plot(a,b, col="red")
What I get is a plot that looks as expected except the x-axis is mostly
red. Can anyone reproduce this
2002 Mar 21
1
help with print and ways to display results
Hi all,
I have some (stupid) problems to display results and
i don't find a solution.
1-
res<-c(1,2,3)
I would like to display
>Results are 1 2 3
The following command cat(paste("Results are ",res,"\n")) give me
>my results are 1 my results are 2 my results are 3
2- res<-cbind(c(1,2),c(2,3))
I would like to display
>Result is the matrix 1 2
2004 Aug 19
2
proposed change to [.POSIXct
R developers,
The "tzone" attribute is stripped from a POSIXct object when the subscript
command is called ("[.POISXct"). This results in dates being printed in the
locale specific format after a subscript operation is applied to a POSIXct
object which has cause several problems for me in the past.
Here is an example of this problem under R 1.9.1:
> x <-
2003 Nov 19
5
ISOdate returns incorrect date?
Dear all,
I have found the following (for me) incomprehensible behaviour of
ISOdate (POSIXct):
> ISOdate(1900,6,16)
[1] "1900-06-15 14:00:00 Westeurop?ische Sommerzeit"
> ISOdate(1950,6,16)
[1] "1950-06-16 14:00:00 Westeurop?ische Sommerzeit"
Note that in the first case I get the 15th of June back, not the 16th as
I would have expected!
This happened under R-1.7.1 on
2024 May 29
1
add only the 1st of May with POSIXct
Thank you Rui for your code.
I basically understood all your suggestions.
I am using an old version of R (version 3.6.3, installed in a server I am not allowed to control), and the new pipe operator does not work.
I tried to run your code without the "|>" operator, but I get an error when I use apply.
Could you please expand your code without the pipe operator?
Thank you again
2002 Mar 01
4
Type III Sum of Squares
Hi,
When doing a two-ways anova in R and comparing my same results with an SPSS
output, I noticed that R calculated type I Sum of Squares. Is it possible to
use Type III Sum of Squares?
Thanks,
S?bastien Plante
Institut des Sciences de la Mer de Rimouski (ISMER)
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read
2003 May 11
1
lines(aline, type = 'b', col = "blue) does not work for POSIXct plot.
Hello,
x <- ISOdate(2003, 4, 1:30) # POSIXct vector
y <-c(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30)
aline <- c(30,29,28,27,26,25,24,23,22,21,20,19,18,17,16,15,14,13,12,11,10,9,8,7,6,5,4,3,2,1)
plot(x, y, xaxt = 'n', main = 'Number of Stuff for the Project, April 2003', xlab = 'Report Time', ylab = 'Number of
2012 Jul 09
1
c(a, b) for POSIXct objects with tzone attributes?
Hello:
What is the recommended method for retaining the tzone attributes
when concatonating POSIXct objects?
> (d1 <- ISOdate(1970,1,1)) # Sets the tzone attribute = GMT
[1] "1970-01-01 12:00:00 GMT"
> (d1.2 <- c(d1, d1)) # c(..) strips the tzone attribute, displays in
the time zone of the operating system
[1] "1970-01-01 04:00:00 PST" "1970-01-01
2024 May 28
1
add only the 1st of May with POSIXct
?s 16:23 de 28/05/2024, Stefano Sofia escreveu:
> Dear R-list users,
>
> From an initial and a final date I create a sequence of days using POSIXct.
>
> If this interval covers all or only in part the months from May to October, I need to get rid of the days from the 2nd of May to the 31st of October:
>
>
> a <- as.POSIXct("2002-11-01", format =
2016 Apr 18
4
as.Date
Dear All,
I have a data set containing year, month, day and counts as shown below:
data <- read.table("data.txt", col.names = c("year", "month", "day", "counts"))
Using the formula below, I converted the data to as date and plotted.
new.century <- data$year < 70
data$year <- ifelse(new.century, data$year + 2000, data$year + 1900)
2007 May 03
1
A question about POSIXct
Dear List:
I have a simple two-column data set in .csv format, with the first column
being the date and second column being some value. I use read.csv() to
import the data as follows:
x <- read.csv("myfile.csv",header=T, dec=".", colClasses=c(Date="POSIXct"))
The structure of x is:
> str(x)
`data.frame': 2959 obs. of 2 variables:
$