Displaying 20 results from an estimated 8000 matches similar to: "sqlFetch on MySQL-DB"
2008 Apr 11
1
Error in fromchar(as.character(x)) : character string is not in a standard unambiguous format
Hello,
I was hoping for advice regarding resolving the above error.
I have a csv file that contains the following variable:
$ Order.Made.Date : Factor w/ 299 levels
"1-Apr-08","1-Aug-05",..: 278 285 91 286 159 132 108 261 282 147 ...
I want to calculate a variable named F.length, which is today's date
minus the values contained in the variable:
2002 Feb 28
1
Bug in julian() (PR#1332)
Full_Name: Michael Jacob
Version: 1.4.1
OS: Windows 2000 SP2
Submission from: (NULL) (195.27.237.226)
Hi,
there seems to be a bug in julian():
> Sys.getlocale()
[1] "LC_COLLATE=English_United States.1252;LC_CTYPE=English_United
States.1252;LC_MONETARY=C;LC_NUMERIC=C;LC_TIME=English_United States.1252"
> julian(Sys.time())
Error in fromchar(x) : character string is not in a
2009 Jan 21
3
Error as.Date on Invalid Dates
Hi All,
I have an script in R which accepts user inputs for certain parameters,
particularly dates, which the user inputs as character strings.
eg:
> date1 <- "2009-01-21"
The script later parses the input via the as.Date function:
> as.Date(date1)
However, as.Date encounters an error when the string does not represent an
actual date.
eg:
> date1 <-
2001 Oct 04
1
get.hist.quote does not work (PR#1116)
Full_Name: Arto Luoma
Version: 1.3.1
OS: Windows 98
Submission from: (NULL) (153.1.53.119)
Hi!
The function get.hist.quote in the package tseries (Version 0.7-6) does not work
in
my computer.
I found that it uses the function strptime which did not "understand" English
month
names in my Finnish locale (see bug report 811). I changed the regional settings
to
be English (UK) and
2004 Oct 11
5
read "4-jan-02" as date
Dear R users,
I have a column with dates (character) in a data frame:
12-Jan-01 11-Jan-01 10-Jan-01 9-Jan-01 8-Jan-01 5-Jan-01
and I need to convert them to (Julian) dates so that I can
sort the whole data frame by date. I thought it would be
very simple, but after checking the documentation and the
list I still don't have something that works.
1. as.Date returns the error below. What am I
2008 Aug 06
3
Help in running Stata dataset in R
Dear All,
I installed R 2.7.0 and tried to call a dataset i had ealier own called
on R2.6.2 but i keep on getting an error:
use("maltreat.dta")
Error in fromchar(x) :
character string is not in a standard unambiguous format
Tried doing the same with R2.7.1 but i get the same error.
However if i call the same on R 2.6.2, there is no error:
use("maltreat.dta")
> des()
2006 Jul 07
3
Converting data frame to zoo
Dear list,
I know this is really basic question but I just couldn't get anything
to work. (I did a R site search with keywords "zoo" and "data frame" but
the server timed out on me.)
I have a time series which has the following (typical) format,
DATE Open High Low Close
Volume
01-JAN-2006 5.25 5.25
2007 Dec 31
1
read.dta error after OSX change in time zone
Hello all,
I recently moved from the US to Africa & on changing my time zone
in the OSX system preferences from EST to GMT+3 ( East Africa) on
attempting to use read.dta using the foreign package began
getting an error of:
"Error in fromchar(x) : character string is not in a standard
unambiguous format"
This error goes away & the data is correctly read in when
2002 Jul 18
1
tseries (get.hist.quote)
Hi,
i really positive surprised when i found the "get.hist.quote" but
didn't now
why i get with the examples from Online-Help errorMessages.
Perhaps their is a problem with POSIX and my OS WIN2000/R1.5.1 ?
Thanks for advance & regards,Christian
$ ibm <- get.hist.quote(instrument = "ibm", start = "1998-01-01")
trying URL `
2006 Jun 23
3
Problems with weekday extraction from zoo objects
Hi Folks!
I'm struggling with dates - but enough about my personal life.....
I have two daily time series files. In one (x) the date format is Y/m/d
and the other (y) is d/m/y. I used read.zoo on both and they read into
R with no problem.
Then I use: weekdays(as.Date(x$DATE)) and get what I expect - all the
days of the week in my data set.
When I use:
2001 Oct 29
1
Help with 'get.hist.quote' on tseries
Hi ALL:
I am trying to use get.help.quote from library(tseries). I tried
to run the example from help(get.hist.quote) but R complained. Here
is the command I used and the response:
ibm <- get.hist.quote(instrument = "ibm", start = "1998-01-01")
trying URL
2004 Jun 02
2
Bug with date 1970-01-01 on Windows (PR#6929)
Full_Name: Martin Lenze
Version: 1.8.0 alpha (2003-09-18)
OS: Microsoft Windows 2000 [Version 5.00.2195], SP4
Submission from: (NULL) (82.82.76.131)
Seems to be related to PR#1332...
Hello,
I get:
> Sys.getlocale()
[1] "LC_COLLATE=English_United States.1252;LC_CTYPE=English_United
States.1252;LC_MONETARY=C;LC_NUMERIC=C;LC_TIME=English_United States.1252"
>
2001 May 15
1
what happende to as.POSIC.ct ???
In my 1021-version I get:
> version
_
platform i386-pc-mingw32
arch x86
os Win32
system x86, Win32
status
major 1
minor 2.1
year 2001
month 01
day 15
language R
> as.POSIXct( "1970/01/01" )
[1]
2004 Feb 14
2
converting data to date format
Dear all,
I import my data from a csv-file containing one row with date-entries. How
can I tell R to treat this data as dates?
I've tried to bring it in character-format (as.charachter()) followed by
as.POSIXlt() but I get an error message, that the character string is not in
a standard unambiguous format, although the date is of format yyyy-mm-dd
(what is standard format according to R
2004 Mar 08
5
years from as.POSIXlt
Hi,
how it's possible to extract the year and the number
of days from Julian date. i'm little confused about the last two
functions and ?years .
EDATE comes from sqlQuery with as.is=T
EDATE <- as.POSIXlt(datvears$ENROLLDAY)
Many thanks, Christian
> EDATE[1:5]
[1] "2000-06-30 11:25:01" "2000-06-30 11:39:55" "2000-06-30 12:11:11"
[4]
2007 Sep 14
2
Date vs date
I wrote the date package long ago, and it has been useful. In my current task
of reunifying the R (Tom Lumley) and Splus (me) code trees for survival, I'm
removing the explicit dependence on 'date' objects from the expected survival
routines so that they better integrate. Comparison of 'date' to 'Date' has
raised a couple of questions.
Clearly Date is more
2002 Aug 28
1
RODBC: sqlFetch and its argument sqtable
Calling function "sqlFetch" in library(RODBC) and specifying a character
string as 2nd argument, I get an error I don't understand:
library(RODBC)
channel <- odbcConnect("mydatabase.mdb", case="msaccess")
sqlFetch(channel, "mytable")
# this works fine
tabname <- "mytable"; sqlFetch(channel, tabname)
# this gives an error:
# Error in
2007 Feb 16
0
Request: make as.POSIXlt generic
In the base package, as.POSIXct() is an S3 generic function, but
as.POSIXlt() is not. As shown below, the current implementation is
already crying out to be refactored into a generic function with methods
for various classes. It calls "inherits" five times. Not only is this
bad style, it also disallows me or anyone else from making as.POSIXlt()
work with other kinds of time-ish
2002 May 11
2
RODBC sqlFetch
Hi,
Thanks for showing me how to use RODBC and odbcConnect.
Now works nicely. The question I've got now is:
noms <- list.files(pattern=".DBF")
# removing extension names:
noms <- sapply(noms, function(x) as.character(strsplit(x,".DBF")) ,
USE.NAMES=F)
for (i in 1:length(noms)) {
s <- sqlFetch(bdades, noms[i])
# etc.
}
But it seems that sqlFetch()
2004 Nov 09
1
colnames argument in sqlFetch backwards? (PR#7355)
Full_Name: Bert Gunter
Version: 2.0.0 patched
OS: Win2000
Submission from: (NULL) (192.12.78.250)
The TRUE/FALSE options of the colnames argument in sqlFetch (RODBC) seem to be
reversed, at least for .xls files.
## z is a connection to an xls workbook opened by odbcConnectExcel()
> dat<-sqlFetch(z,'SuccessRates',colnames=FALSE)
> dat[1:5,]
RecID Name Run Grams Lost Run