Displaying 20 results from an estimated 200 matches similar to: "sdate<-as.POSIXct(strptime(date,format="%m/%d/%Y %H:%M"))"
2011 Jun 14
1
Putting commas in between character strings
I have a number of strings in a vector, and want the output to be seperated
by commas.
> t [1] "35004" "35005" "35006" "35007" "35010" "35014" "35016"
So I want want it to look like:
"35004", 35005", "35006", "35007",...
Can anyone help? I initially thought strsplit would be the
2017 Sep 11
4
show 0 at y axis in xyplot lattice
Dear all
I am trying to make a plot in xyplot lattice by groups. I would like to show "0" in y axis but I don't want to be aligned with the x axis. I want to be a little bit above.
I have tried many options but I don't get what I want. I also tried ylim=c(0, 80) but both 0 and 80 are fully aligned with the x-axis and the upper boundary of the plot, respectively:
xyplot(upper.zn +
2017 Sep 11
2
Σχετ: show 0 at y axis in xyplot lattice
Dear Bert and all,
I am really sorry. This is the full code:
dat<-read.csv("example.csv")attach(dat)
sdate<-as.Date(Date, format="%Y-%m-%d")
#change the colour of the strip background
my.settings <- canonical.theme(color=FALSE)
my.settings[['strip.background']]$col <- "blue"
dat_key <- list(space="right",
??????????????? lines =
2017 Sep 11
0
show 0 at y axis in xyplot lattice
1. Not reproducible since my.settings, dat_key, sdate not provided.
2. Why did you not try something like ylim = c(-5,80) ?
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along and
sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )
On Mon, Sep 11, 2017 at 12:33 PM, Maria Lathouri via
2017 Sep 11
0
show 0 at y axis in xyplot lattice
Not reproducible, as we have neither "example.csv" nor "Date" .
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along and
sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )
On Mon, Sep 11, 2017 at 2:38 PM, Maria Lathouri <mlathouri at yahoo.gr> wrote:
> Dear
2017 Sep 12
2
Σχετ: show 0 at y axis in xyplot lattice
Dear all,
Thank you very much for the help. ylim=c(-5, 80) worked.?
Regarding the reproducible example, I used dput () and saved the file as txt. It is not the first time that I used this way and normally it works. Because when I try to attach a .csv file with the data, most of the time it doesn't go through.?
I will know for the next time.?
Many thanks.
Regards,Maria
???? 2:11 ?.?.
2009 Jun 08
4
increase number of ticks on x axis of dates
My x axis is a series of daily dates (e.g., 01/01/2000, 01/02/2000,
etc.) from 2000 to end of 2008. The default only gives me 4 ticks. I
want more. Why doesn't this work?
sdate<-as.POSIXct(strptime(date,format="%m/%d/%Y"))
plot(ppt~sdate,type="l",ylim=c(0,47),col=1,lwd=1,pch=16,ylab="Salinity,
psu",xlab="Year",las=1,main="Duck Key
2008 Apr 23
1
Time arithmetic
I am a bit worried I am reinventing the wheel. Isn't there a calendar
system in R?
I have written a function to add months to a date and return the number of
days resulting. I am newish to R so I am hoping there is a package that
can do this sort of date arithmetic for me...
Worik
DaysInMonths <- function(s,d){
## Days in d months from s
sdate <- MSTD(s)
## Get day, month
2017 Sep 12
0
show 0 at y axis in xyplot lattice
Hi Maria
Rule 1 make sure your data is in the right format
dat <- source("G:/1/savedat.txt")
> dat
$value
Location Date Zn2 upper.zn lower.zn
1 upstream 2016-04-27 29.92477 55.59800 13.912207
2 spill 2016-04-27 12.84040 22.07006 6.964934
3 downstream 2016-04-27 22.49673 41.60901 11.739109
4 upstream 2016-06-28 23.98425 45.60219 10.690640
5
2005 Jul 18
5
colnames
Hi,
I have a matrix with column names starting with a character in [0-9]. After some matrix operations (e.g. copy to another matrix), R seems to add a character 'X' in front of the column name. Is this a normal default behaviour of R? Why has it got this behaviour? Can it be changed? What would be the side effect?
Thank you.
Regards,
Gilbert
[[alternative HTML version deleted]]
2010 Feb 23
1
Problem with strptime generating missing values where none appear to exist
Dear R Helpers,
I am having difficulty with strptime. I wish to find the differences between
two vectors of times. I have apparently no difficulty to convert the vectors
to the appropriate format using strptime. But, then difftime does not
calculate all the differences.
Here is the code and output:-
dob=strptime(as.character(datx$BDT),'%d-%b-%y'); dob$year=dob$year-100
2017 Sep 12
0
Σχετ: show 0 at y axis in xyplot lattice
Dear Maria
The file you attached to your first e-mail did come through but I think
some people on the list must have missed it.
Michael
On 12/09/2017 12:54, Maria Lathouri via R-help wrote:
> Dear all,
> Thank you very much for the help. ylim=c(-5, 80) worked.
> Regarding the reproducible example, I used dput () and saved the file as txt. It is not the first time that I used this way
2012 Oct 01
2
Hmisc describe error
Describe fails for me with a message similar to what was an issue in 2008 and got fixed according to posts.
R version 2.15.0 (2012-03-30)
Copyright (C) 2012 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: i386-pc-mingw32/i386 (32-bit)
# output truncated
> options(chmhelp = FALSE, help_type = "text")
> .help.ESS <- help
>
2009 Jul 30
2
Question regarding sqldf
Hello,
I am having a problem using sqldf. I'm trying to choose a subset of
observations from a data set based on the date and maximum value of a
variable by date.
Here is the code I am using:
test<-sqldf("select distinct * from bextuse group by sdate having
bext=max(bext)",method="raw");
The result I get back is a data frame with 0 rows and 0 columns. I have
tried
2004 May 24
9
Combo Box
>> You really want to call get_value. Unfortunately, that''s not
implemented
>> in wxRuby 0.3.0.
>I found to my surprise that this method is actually working, but only
in the
>example code that comes with wxRuby one-click install for Windows.
@combo.get_label seems to work for me.
See sample code below.
HTH,
Assaph
----- CODE -----
require ''wxruby''
2005 Feb 28
3
test/unit error report for win32-service
Dan,
I am assuming that the version in CVS is the most current one.
Report follows.
-- shanko
------------------------------------------------------
C:\win32utils\win32-service\test>ruby tc_service.rb
This test will stop and start your Clipboard service, as well as
pause and
resume your Schedule service. This is harmless unless you are actually
using these services at the moment you
2004 May 16
1
RE: wxGrid example
Kevin, should we check this in to CVS as one of the our distributed samples?
Curt
-----Original Message-----
From: Shashank Date [mailto:sdate@everestkc.net]
Sent: Sunday, May 16, 2004 4:30 PM
To: wxruby-users@rubyforge.org
Cc: curt@hibbs.com
Subject: wxGrid example
I am using the binary install of wxRuby 0.3.0 on WinXP(Home)
I could not find an example of using wxGrid, so I
2010 Oct 15
1
Downloading file with lapply
I'm still getting familiar with lapply
I have this date sequence
x <- seq(as.Date("01-Jan-2010",format="%d-%b-%Y"), Sys.Date(), by=1) #to
generate series of dates
I want to apply the function for all values of x . so I use lapply (Still a
newbie!)
I wrote this test function
pFun <- function (x) {
print(paste("This is: ",x,sep=""))
}
When I
2009 Dec 14
6
write.csv and header
Dear list,
I would like to export a matrix to a TXT-File by using write.csv (not
necessarily). Is there a way to add a header (with additional
informations concerning the project) spanning multiple lines to this
file before the actual data are listed up? Should look like this:
date:
filename:
number of permutations:
------------
data (as a matrix)
Any suggestions? Thnx in advance.
2008 Oct 14
2
Getting frustrated with RMySQL
Getting the basic stuff to work is trivially simple. I can connect, and, for
example, get everything in any given table.
What I have yet to find is how to deal with parameterized queries or how to
do a simple insert (but not of a value known at the time the script is
written - I ultimately want to put my script into a scheduled task, so the
analysis can be repeated on updated data either daily