Displaying 20 results from an estimated 10000 matches similar to: "POSIX problem"
2009 Nov 13
2
linear model and by()
Hello R list,
This is a question for anyone who has used the by() command. I would like to
perform a regression on a data frame by several factors. Using by() I think
that I have able to perform this using the following:
> lm.r <- by(master, list(Sectionf=Sectionf, startd=startd), function(x) lm
(tot.c ~ starttime, data = x))
So that is, I would like to perform separate regressions for
2003 Sep 02
1
convert character to POSIXct
Dear list-members,
I would like to calculate the difference between two points in time. To convert a 'time (GMT)'-character with the format "1/1/1999 01:01:01" into an object of class "POSIXct"', I first use the strptime() as suggested in the details help(as.POSIXct).
e.g.
starttime<-strptime("1/1/1999 01:01:01",format="%d/%m/%Y %H:%M:%S")
2008 Feb 27
2
All Day Events
I must be stupid because this cannot be this hard.
I''m trying to build an all day calendar event. In most clients it shows up as an entry at the top of the day rather than blocking out the whole day with an event.
I have a bit of code that looks like this...
cal.event do
dtstart DateTime.parse("#{startDate.year()}-#{startDate.month()}-#{startDate.day()}")
dtend
2009 Feb 08
1
[libvorbis] Bugfix: seek broken for large files and on pure 32 bit architectures
In file vorbisfile.c, function
int ov_pcm_seek_page(OggVorbis_File *vf,ogg_int64_t pos)
the calculation of the approximate seek point causes an overflow for
very large files and on pure 32 bit architectures.
/* take a (pretty decent) guess. */
bisect=begin +
(target-begintime)*(end-begin)/(endtime-begintime) - CHUNKSIZE;
The temporary expression (target-begintime)*(end-begin)
2012 Aug 01
4
how to calculate seasonal mean for temperatures
Hello everybody,
I need to calculate seasonal means with temperature data for my work.
I have 70 files coming from weather stations, which looks like this for
example:
startdate <- as.POSIXct("01/01/2006", format = "%d/%m/%Y")
enddate <- as.POSIXct("05/01/2006", format = "%d/%m/%Y")
date <- seq(from = startdate, to = enddate, by =
2012 Jun 08
3
Resolution issue with exporting plots from R and write tables in Latex code for producing pdf document
Dear R users
I am trying to exporting plots from R to an external folder, or to the
working directory, but the resolution of plots (pdf file) largely reduced.
Any way I can get same quality as my original plots?? e.g. I tested the
plotting part using one example and obtained pretty good (/readable)
quality for each plot in the (4*4) multiple graph. But when I did the loop
and tried to export
2004 Dec 21
1
Referencing a table''s fields.
Hello,
I recently set up a rails application, and wanted to provide helper methods in my model class.
I was confused that the class DOESN''T refer to its fields as instance variables. I merely had to
type in the field names to be able to work with their data.
Here''s an example:
I have a "Chessgame" class with a begindate and an enddate. To get the number of hours
2006 Mar 24
3
Date in dataframe manipulation
Hi,
I have a dataframe with many columns, including date and I want to keep
only a few of the columns including date column.
I used the following command:
with(FireDataAppling, cbind(STARTDATE, County, TOTAL, CAUSE)
It works, but the date becomes days from Jan 1, 2001.
FireDataAppling$STARTDATE[1] gives
[1] 2001-01-04 00:00:00
1703 Levels: .........
After the cbind command, the entry
2005 May 11
2
time zones, daylight saving etc.
Hi, I have a whole bunch of data, which looks like:
15/03/2003 10:20 1
15/03/2003 10:21 0
15/03/2003 12:02 0
16/03/2003 06:10 0
16/03/2003 06:20 0.5
16/03/2003 06:30 0
16/03/2003 06:40 0
16/03/2003 06:50 0
18/03/2003 20:10 0.5
etc. (times given on a 24 hour clock)
and goes on for years. I have some code:
2003 Feb 21
1
POSIX problem in New Zealand (PR#2570)
Full_Name: Arni Magnusson
Version: 1.6.2
OS: Windows XP
Submission from: (NULL) (210.48.49.68)
Hi there. I'm experiencing unexpected behaviour from as.POSIXct:
> as.POSIXct("1969-12-24")
[1] "1969-12-23 23:00:00 New Zealand Standard Time"
> as.POSIXlt("1969-12-24")
[1] "1969-12-24"
> as.POSIXlt("1969-12-24")+1
[1] "1969-12-23
2007 Oct 25
1
Strange behavior with time-series x-axis
I recently called plot(x,y) where x was an array of POSIXct timestamps,
and was pleasantly surprised that it produced a nice plot right out of
the box:
z <- as.POSIXct(c("2006-10-26 08:00:00 EDT","2007-10-25 12:00:00 EDT"))
x <- seq(z[1],z[2],len=100)
y <- 1:100
plot(x,y,type="l")
The X axis had nice labels, one tick mark every other month. (Plotting
on
2008 Dec 10
3
How to fix broken ogg/theora files
Hi there,
I haven't been on this list until now, so I wasn't aware of this problem until last night ;-) - sorry for that.
I am working on a patch for oggCut for that issue (looks good actually but I would like to do some testing befor I can release a patch.)
Normal players are not effected by the page time misordering, so I took this issue as "minor". The reason for the
2006 Feb 08
6
can''t get date_select to work
Hi,
I render a couple of date_select fields, the HTML looks fine, I can
see the values submitted back to the server, but AR doesn''t pick them
up from the hash in Booking.new(params[''booking'']).
I''ve got a ''booking'' object with parameters product, startdate and
enddate.
HTML snippets:
<select
2006 Mar 07
1
PLEASE HELP ,a2billing problem with call duration
Regards!
During the use of areski a2billing software I'm getting same problem all the time.
Actually, after 15 minutes of speaking to someone over calling card, connection brakes.
Installation was as smooth as it could be so I don't think I made same kind of a mess in that domain. This is the only problem in the aplication.
In the logs everything seems to be fine.
I'am sending You
2006 Apr 25
1
Array of dates/times from time.now till nextweek
Hi,
I would like to make @dates in my controller.
I tried the following:
startdate = Time.now
enddate = startdate.next_week
for enddate > startdate
@dates << startdate
startdate = startdate.tomorrow
end
But I get an errormessage when I check the syntax:
"warning: useless use of a variable in void context"
Anyone?
Thanks!
Steven.
--
Posted via
2012 Nov 02
2
Date format conversion from "2012-09-20" to "2012:09:20"
Hi R,
How to get the range of values form startDate to lastDate as given below?.
#*****************************************************************
# Load historical data
#******************************************************************
library('quantmod')
endDate =Sys.Date()
startDate = as.Date(endDate-30, order="ymd")
dataspy = getSymbols("SPY", from = startDate,
2006 Jul 26
8
change text_field_tag class
in my booking / _form I have the following input fields : (startdate and
endate)
<div>
<label for="startdate">Booking Start Date</label><br />
<%= text_field_tag(''startdate'', @startdate, {:class => @startdateclass,
:readonly => "readonly", :maxlength => "25"} ) %>
<%= observe_field("startdate",
2006 Jul 06
3
Understanding date_select naming conventions
I am using the date_select helper to generate date select elements in a
form.
I notice that the generated HTML shows that these selects have the
following names:
Month: current_job[StartDate(2i)]
Day: current_job[StartDate(3i)]
Year: current_job[StartDate(1i)]
I''m assuming that the Xi identifiers somehow specify the appropriate
date part from a date or time value.
Can anyone
2008 Nov 19
2
Exclude holidays in a subset of dates?
Hi All,
I am iterating through dated materials, with variable start and end dates,
and would like to skip procedures everytime I encounter a weekend or
holiday. To do this, I thought the easiest way would be to create a
TRUE/FALSE vector corresponding to each day where it is TRUE if a workday,
and FALSE if a weekend or holiday.
So far I have been able to do this for weekdays:
startDate <-
2008 Feb 20
4
plotting every ith data point?
Hello, fellow R enthusiasts.
Ok, I've been racking my brain about this small issue, and between
searching the help archives and reading through the plot-related
documentation, I can't figure out how to achieve my desired endpoint
without some ugly, brute force coding.
What I would like to do is make a plot in which only a subset of my
data are plotted, but in regular intervals, such as