similar to: Time From String

Displaying 20 results from an estimated 200 matches similar to: "Time From String"

2006 May 21
3
Using ParseDate in for loop
Hi, I''m trying to use ParseDate within a for loop but I get this error: can''t dup NilClass Any suggestions for making this work? Thanks, -Jason
2006 Jun 05
3
How to get dd mmm and yyyy from dd-mmm-yyyy
The input values could be something like this: 01-Dec-2006 01-December-2006 1-June-2006 Is there an easy to way to get the three variables populated dd, mmm and yyyy for any of the above input values? I tried to look at regex but couldn'' anything simple. Thanks -------------- next part -------------- An HTML attachment was scrubbed... URL:
2009 Oct 29
1
lmer and negative binomial family
Dear listers, One of my former students is trying to fit a model of the negative binomial family with lmer. In the past (two years ago), the following call was working well: m1a<-lmer(mapos~ninter+saison+milieu*zone+(1|code),family=neg.bin(0.451),REML=TRUE,data=manu) But now (R version 2.9.2 and lme4 version 0.999375-32), that gives (even with the library MASS loaded):
2008 Feb 14
1
Cholmod error `matrix not positive definite'
Dear R-users, I'm new to R, so my apologies if this question doesn't make sense. I've tried the following model in lmer, and it works perfectly: model<-lmer(aphids~densroot+zone+(1|zone/site), family=quasipoisson) But if I try the exact same model with a different variable, totmas, the model looks as follows: model<-lmer(aphids~totmas+zone+(1|zone/site), family=quasipoisson)
2006 Jan 28
1
Method for returning a random date between two dates
Hi, I''m trying to create a method to return a random date within a range. So far, I''ve come up with this... require ''parsedate'' def random_date (a, b) adate = ParseDate.parsedate(a) bdate = ParseDate.parsedate(b) atime = Time.local(*adate) btime = Time.local(*bdate) atime + (rand * (atime - btime) ) end ...and it doesn''t seem to
2002 Jul 06
2
Time attributes in LDAP SAM
I am updateding my LDAP presentation (ftp://kalamazoolinux.org/pub/pdf/ldapv3.pdf) to include a section on the Samba 2.2.x LDAP backend. But I can't find any definititive documentation on the "time" attributes: pwdLastChange, pwdMustChange. Either how the time is encoded or exactly what they mean. I've seen post saying they are hexidecimal (although they don't look it)
2006 Jun 15
4
parse only seem to understand US date format
I''ve tried Time.parse() and DateTime.parse() but they interpret the date as US format. Is there any way to tell it to interpret as dd/mm/yyyy? -- Posted via http://www.ruby-forum.com/.
2006 Jul 17
2
european date format
hi, overhere users go nuts if they have to enter the date in iso format, so i have to make my applications in such a way that not only dates are displayed in the "dd-mm-yyy" format but also can be entered in that way. somewhere i found this code to put in the environment script: ActiveSupport::CoreExtensions::Time::Conversions::DATE_FORMATS.update( :default => ''%d/%m/%Y
2006 May 11
4
string to date/time?
Hey All, Anyone know of a library for parsing "human" dates, like "this friday" or "2 days ago"? I used to use strtotime in php, but starting from here; http://wiki.rubyonrails.com/rails/pages/PhpStrtotime and doing lots of googling, I haven''t been able to find anything similar for ruby. I know of javascript solutions to this, but I''d need to do
2010 Mar 14
3
likelihood ratio test between glmer and glm
I am currently running a generalized linear mixed effect model using glmer and I want to estimate how much of the variance is explained by my random factor. summary(glmer(cbind(female,male)~date+(1|dam),family=binomial,data= liz3")) Generalized linear mixed model fit by the Laplace approximation Formula: cbind(female, male) ~ date + (1 | dam) Data: liz3 AIC BIC logLik deviance 241.3
2005 Sep 06
1
US Date Handling in Rails
My application is built on Rails and MySQL. It will only be accepting US formatted dates as input, however both Rails and MySQL are oriented around ISO the format. I know I can convert a good portion of the entries using ParseDate::parsedate but it does not appear this is how the conversion is taking place when data is being transferred from the params hash into model members. Say I have a field
2006 May 13
1
undefined method `strftime'', being called from a partial.
Hi, I''m having an issue with calling a function that I''ve defined in ApplicationHelper called format_time: module ApplicationHelper def format_time(time) time.strftime("%a %b %d, %I:%M%p") end end I use this function in my views to format the Time.now that I would have stored in my tables as a DATETIME. I''m able to use this function, without any
2009 Jan 17
2
Call file in the future
Hello, I read a thread on the asterisk dev list (call file handling suggestion) May i have some comment/opinion on these two ways below to place a call file in the future ? (from the wiki and the asterisk book but added typos and stupidity come from me) The best is ? (and should work ?) tmsp = the delay in future.. say 100 seconds exten=> ra,n,System(NOW='date %S') exten=>
2008 Apr 17
1
LVM + xfs + Shadow copy
hi there, i begin to install shadow copy VFS mod function in samba 3.0.24-6etch9, after i see the same function at win2003srv, i think it could be very useful, if i gonna make it under DEB, but at the moment i'm really get stucked, i try to describe what's the point now; 1 - load shadow_copy mod in smb.conf vfs objects = shadow_copy 2 - install shadow copy client in WinXPProf 3 -
2006 Jan 16
3
String date parsing
Does anyone know if a Ruby package has been written to handle functionality similar to php''s strtotime(). I''m looking for something that can parse almost any string (such as "1 day ago", "+1 week", "last tuesday") into a timestamp. I''ve played with ParseDate, but it doesn''t seem to do what I need. Any suggestions? Derek
2006 Mar 01
3
Convert Date to Time
Hi, How do i convert a Date to a Time?? I have a date returned from sql and i need to be able to use handy functions like next_week or beggining of week. Any help appreciated Thanks, Chris -- Posted via http://www.ruby-forum.com/.
2019 Oct 16
2
BackupPC v4 from epel
Hello Everyone, Has anyone tried to install BackupPC v4 on CentOS 8 from epel? I just did and this happened: [root at resurrect ~]# dnf --enablerepo epel install BackupPC Last metadata expiration check: 0:18:41 ago on Tue 15 Oct 2019 08:03:59 PM EDT. Error: Problem: conflicting requests - nothing provides par2cmdline needed by BackupPC-4.3.1-2.el8.x86_64 - nothing provides
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 May 16
4
question about strftime when called from partial.
Hi, I''m calling a helper I''ve written - format_time() that is called from my views with a given time that was selected from my database and was returned to the view via an instance variable. When I call format_time from a partial, I see that I get some kind of String error and the partial won''t render. Basically, the object being passed in to format_time is already a
2005 Mar 03
12
bug in postgresql ''now'' time handling??
line 212 of postgresql_adapter.rb is return Time.now.to_s if value =~ /^\(''now''::text\)::(date|timestamp)/ i don''t think this will work. in postgresql the field ''now'' is pinned to the SAME TIME for the duration of a transaction. eg. if you do begin transaction; insert into t values(42, ''now''); # sleep one minute