Re: [R] switch of cex adjustment with mfrow?

2017-08-04 Thread Jannis via R-help
good to make the documentation a bit more specific here? Best Jannis S Ellison schrieb am 12:31 Donnerstag, 3.August 2017: > use > > par(mfrow=c(2,2), cex = 1) This does work as written. But when I first checked single-call setting, an  mfrow change to cex in the same call s

[R] switch of cex adjustment with mfrow?

2017-08-02 Thread Jannis via R-help
Dear list members, i am trying to create multiple figures with identical layout (i.e. font sizes etc.) for a publication created with Latex. To do so (i.e. to get identical font sizes) I save all plots as a pdf with widths and heights as they would later appear in the paper (to prevent scalin

Re: [R] solution for r-help to the problem of yahoo addresses bouncing?

2014-05-19 Thread Jannis
Hi David, thanks for your reply. On 16.05.2014 23:07, David Winsemius wrote: On May 16, 2014, at 2:25 AM, Jannis wrote: Hi R users, I suspect this is due to yahoo recently changing its handling of DMARC policies. Yes. It is due to ISP bounces coming back to the ETHZ server. You do not

[R] solution for r-help to the problem of yahoo addresses bouncing?

2014-05-16 Thread Jannis
unces..." I suspect this is due to yahoo recently changing its handling of DMARC policies. Is there anything I can do from my side to change this? Or is the only solution to change the mail provider? Thanks for any hints Jannis __ R-help@r-p

[R] access environment in which an error occoured

2014-04-25 Thread Jannis
se (see my earlier post: http://r.789695.n4.nabble.com/maximum-size-of-dump-frames-files-td4689444.html). Thanks Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-p

[R] maximum size of dump.frames files?

2014-04-25 Thread Jannis
file with the dumped frames is not created. Instead, the process on the cluster seems to be halted. When running the same thing on smaller files (and probably hence smaller objects in the workspace) my mechanisms walks flawlessly with the dump.frames file saved. Any ideas? Jannis

Re: [R] R CMD check and foreach code

2014-03-27 Thread Jannis
lve the problem. Cheers Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

[R] R CMD check and foreach code

2014-03-27 Thread Jannis
can not be found as only the call to foreach creates it (similar to a for loop), but should not the R check consider this? Or is my programming poor? Setting i to any arbitrary value before running foreach makes the error disappear, but this would feel as a really dirty hack. Cheers Jannis

Re: [R] v3.0.1 issue

2013-09-19 Thread Jannis
the symbol you click to start R in the Windows case). Perhaps this solves the issue. Jannis On 18.09.2013 17:54, SOPHIA TSIROPOULOU wrote: [Previously saved workspace restored] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman

[R] big difference between ncdf and RNetCDF ?

2013-09-17 Thread Jannis
(with regards to their functions). I ask because I will give some advice on ncdf and R to a group of people highlighting some of the (possible) differences. Thanks a lot Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo

Re: [R] prevent mfrow from changing cex

2013-09-14 Thread Jannis
Thanks for your reply, Gert. I was aware of the documentation. Thanks for your hint. In addition I have found that running par(mfrow = c(2,2)) par(cex=1) sequentially also has the desired result. Cheers Jannis On 13.09.2013 19:01, Bert Gunter wrote: ?par documents this behavior. I think if

[R] prevent mfrow from changing cex

2013-09-13 Thread Jannis
setting cex to a value that would be 1 if modified by mfrow). In the end my desire to have the software do what I tell it to do and not what its programmers think I would want to do was one of the reasons to move away to R from (in)famous Excel ;-). Cheers Jannis

Re: [R] substituting string variable in expression with its value

2013-09-12 Thread Jannis
Hi Gerrit, thanks for your suggestion. I want to create some code were I can supply the 'm*s^{-2}' part as an argument to a function and which evaluates this as an expression to use Rs mathematical annotation features in the labels. Any further ideas? Jannis On 12.09.2013 14:

[R] substituting string variable in expression with its value

2013-09-12 Thread Jannis
' plot(1,1, main=expression(paste(a, " [", b, "]"))) This, however, does not work as a and b are not treated as variable names in this case. Does anyone have a solution for this? Cheers jannis __ R-help@r-project.org mailing list https:/

Re: [R] Plotting time vs number

2013-08-28 Thread Jannis
Hi Mohan, as I said, it is difficult to help you without beeing able to reproduce your plots. Could you please send to the list: 1. the exact command you use to create the plot 2. The output of dput(data) Thanks Jannis On 28.08.2013 14:35, mohan.radhakrish...@polarisft.com wrote: Hi

Re: [R] Plotting time vs number

2013-08-28 Thread Jannis
mps would still be there). If you need the points as well, use points() to plot a point plot over the already existing line plot. Does this solve your problem? Jannis On 28.08.2013 13:45, mohan.radhakrish...@polarisft.com wrote: Hi, The plot function draws a broken line. The graph bre

[R] problem with package doMC: ignoring SIGPIPE signal

2013-08-27 Thread Jannis
set up the process. I can only debug this error via dum.frames as I run it non interactively on a cluster machine. When I start the foreach loop manually from within the debugger() environment, I can not reproduce the error. Does anyone have a hint on how to find the cause of this err

[R] using functions from other packages in own package

2013-08-20 Thread Jannis
library() and require() calls? Thanks a lot Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained

Re: [R] getting rid of .Rhistory and .RData

2013-08-14 Thread Jannis
e is saved. Cheers Jannis On 14.08.2013 16:01, Jannis wrote: Well, I have made some tests with the 'no save' option. This only seems to control the saving of .RData files (at least none appeared in the working directory in my tests). A file called .RHistory is still created. I can now put

Re: [R] getting rid of .Rhistory and .RData

2013-08-14 Thread Jannis
somehow I think that R should provide an option not to clutter the working directories in such ways. Or to use one central .RHistory file. Any ideas? Jannis On 14.08.2013 14:33, Jannis wrote: Thanks, I will look into ways to tell ess/emacs to use such options. I am, however, quite sure that I

Re: [R] getting rid of .Rhistory and .RData

2013-08-14 Thread Jannis
Thanks, I will look into ways to tell ess/emacs to use such options. I am, however, quite sure that I have never answered "yes" to the question when quitting R. Cheers Jannis On 13.08.2013 20:21, MacQueen, Don wrote: R --no-save _

[R] internal error -3 in R_decompress1

2013-08-13 Thread Jannis
to dig for the solution (or even the just cause). Jannis R version 3.0.0 (2013-04-03) Platform: x86_64-unknown-linux-gnu (64-bit) locale: [1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C [3] LC_TIME=en_US.UTF-8LC_COLLATE=en_US.UTF-8 [5] LC_MONETARY=en_US.UTF-8LC_MESSAGES=en_US

[R] getting rid of .Rhistory and .RData

2013-08-13 Thread Jannis
Dear R users, occasionally I find .Rhistory and/or .RData files cluttered around in my file structure. Is there a way to tell R not to save such files? Or to use one central location where to save them (if they are of any use)? I have looked through options() to no avail. Cheers Jannis

[R] linking to help pages in other packages

2013-08-09 Thread Jannis
ve represents my understanding (which seems to be wrong) of the respective paragraphs. Thanks a lot Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/postin

Re: [R] multivariate version of aggregate

2013-06-28 Thread Jannis
Thanks a lot to everybody who responded! My solution now looks similar to Ruis and Davids suggestions. Jannis On 28.06.2013 11:00, Rui Barradas wrote: Hello, You can solve your problem using only base R, with no need for an external package. The two instrucitons below are two ways of

Re: [R] multivariate version of aggregate

2013-06-28 Thread Jannis
t;- ddply(.data = testframe, INDICES= indices, .fun = function(x) corr(x[,1], x[,2])) Where the last command would yield the correlations between column 1 and 2 of the first 50 and of the last 50 values. Any ideas? Jannis On 27.06.2013 21:43, Greg Snow wrote: Look at the plyr package, probably

[R] multivariate version of aggregate

2013-06-27 Thread Jannis
Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

[R] showing error line

2013-06-20 Thread Jannis
not, however, show up for the same errors when I use installed packages. Do I have to build these packages in a specific way? Cheers Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting

[R] numeric not equal its value

2013-05-21 Thread Jannis
es seq create such numbers? Thanks a lot Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-con

[R] proper way to handle obsolete function names

2013-04-17 Thread Jannis
. Cheers Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] checkUsage from codetools shows errors when function uses functions from loaded packages

2013-04-10 Thread Jannis
Well, its mentioned in the function itself by library(xxx) or require(xxx). Well, most probably codetools is more aimed towards checking packages in whcih case such information is in the depends section of the package declaration. Best Jannis On 08.04.2013 21:03, Duncan Murdoch wrote: On

Re: [R] checkUsage from codetools shows errors when function uses functions from loaded packages

2013-04-08 Thread Jannis
Thanks for your reply, Duncan. I hoped for an auutomatic way without manually having to load the packages to exist ... Perhaps this time this is not the case. Cheers Jannis On 08.04.2013 20:25, Duncan Murdoch wrote: On 08/04/2013 2:12 PM, Jannis wrote: Dear list members, I frequently

[R] codetools: checkUsage would not report the use of unbinded variables if they are binded later

2013-04-08 Thread Jannis
help Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

[R] checkUsage from codetools shows errors when function uses functions from loaded packages

2013-04-08 Thread Jannis
definition for ‘xxx’ For example: test = function() { require(plotrix) color.legend() } library(codetools) checkUsage(test) Can I tell codetools somehow where to look for these functions without building a full blown package? Cheers Jannis

Re: [R] does R read commands from scripts instantanously or seuqently during processing

2013-03-15 Thread Jannis
t happens if i would start the script via source inside R itself. Thanks again for your suggestions Jannis On 14.03.2013 22:47, Rolf Turner wrote: On 03/15/2013 05:13 AM, Jannis wrote: Dear R community, when I source a script into R via: R --slave < scriptname.R is the whole script fi

[R] does R read commands from scripts instantanously or seuqently during processing

2013-03-14 Thread Jannis
I savely edit the scriptname.R file even when an active R process still runs the command above? Thanks for your help Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://ww

[R] maximum amount of lines of code to be copy pasted to R console

2013-02-05 Thread Jannis
parantheses are balanced (i.e. the code runs when run via source or inside some function). Cheers Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting

Re: [R] functions as arguments to ther functions with inlinedocs

2013-01-25 Thread Jannis
. Thanks agian for replies! Jannis On 24.01.2013 20:02, Rui Barradas wrote: Hello, Sorry, it's RIGHT parenthesis. Rui Barradas Em 24-01-2013 18:54, Rui Barradas escreveu: Hello, Your function declaration has a syntax error, one left parenthesis too much. Corrected it wou

[R] functions as arguments to ther functions with inlinedocs

2013-01-24 Thread Jannis
ine something sequential as an argument like: dummyfunction = function(filters = {a = 1; b > a; b}) {print('test')} I hope I could clarify my problem. Thanks a lot Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listin

[R] problem with opening more than one SOCK cluster with package snow

2012-12-19 Thread Jannis
se packages: [1] stats graphics grDevices datasets utils methods base other attached packages: [1] snow_0.3-10 Thanks a lot Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the post

Re: [R] catching errors in RNetCDF

2012-12-06 Thread Jannis
ot want to critisise anyone for sharing his code! Thanks a lot Jannis On 06.12.2012 12:53, Michael Sumner wrote: Do you want to cause an error or catch one? Try removing the try() and see if that helps. This has nothing to do with RNetCDF you could as easily have caught another more basic error. O

Re: [R] catching errors in RNetCDF

2012-12-06 Thread Jannis
Hi Pascal, Well, as i see it, this is no error, just a simple message printed to the screen claiming that it is an error. All the mechanisms in R to handle errors (e.g a stop of code execution etc) are, however, not initiated. Cheers Jannis On 06.12.2012 02:53, Pascal Oettli wrote: Hi

[R] catching errors in RNetCDF

2012-12-05 Thread Jannis
om that side. Any Ideas? Cheers Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.

Re: [R] list.files, recursively

2012-11-19 Thread Jannis
everybody has to program his own workaroung. So, lets see whether this convinces the people reponsible for these base functions. Cheers Jannis On 18.11.2012 19:02, Rui Barradas wrote: Hello, I believe that's a question for r-devel, but good point. It's docummented that in non

[R] list.files, recursively

2012-11-18 Thread Jannis
have any effect). Would it not be more intuitive and practical to allow the switching off of directory names in both cases? Thanks a lot Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting

Re: [R] multivariate way to aaply on different arrays

2012-10-23 Thread Jannis
there are more efficient ways to solve this. Best Jannis maaply <- structure(function( ##title<< multivariate version of aaply ##description<< apply a function to slices, vectors in different (multivariate) ## multidimensional datacubes. ... ##<<

[R] multivariate way to aaply on different arrays

2012-10-18 Thread Jannis
more) in the same location on another (identically shaped) array. What would be the most efficient way to do this? Is there any multivariate version of aaply? Or other functions? Or some memory efficient and fast way (the datacubes are huge!) to do this by hand? Thanks a lot Jannis

[R] tapply to data.frame or matrix

2012-09-04 Thread Jannis
similar manner to the tapply function? For example, in the follwoing case, I would like to combine columns 1 and two into one vector, and columns 3-4 into another: test = as.data.frame(matrix(1:20, ncol = 5, nrow=4)) test.ind =c(1,1,2,2,2) Thanks a lot! Jannis

Re: [R] strange behaviour when sourcing inside function

2012-08-23 Thread Jannis
ion of the word local and the corresponding boolean values) but if it is, the manual (to me) is misleading. Cheers Jannis On 22.08.2012 21:25, Noia Raindrops wrote: Hello, If argument 'local' is FALSE, 'source' function is evaluating the file in global environment and obje

[R] strange behaviour when sourcing inside function

2012-08-22 Thread Jannis
terpretation of the documentation, both versions should do the same Thanks for your help! Jannis P.S. There seems to be an small typo in the documentation for the 'local' argument ("...FALSE to the environment from source is called...") in case anybody appreciates

[R] internal error -3 in R_decompress1

2012-07-25 Thread Jannis
? What is the best place to start digging for the cause of the error? Running the same line of code interactively or using the output of dump.frames also does not reproduce the error. Cheers jannis __ R-help@r-project.org mailing list https

Re: [R] dump.frames and global environment

2012-07-25 Thread Jannis
of the global environment to this function. As a result, i can access all neccessary objects while debugging. The open question to me is whether a default behaviour of dump.frames which saves the global anvironment automatically would help others as well ? Cheers Jannis On 24.07.2012

Re: [R] dump.frames and global environment

2012-07-24 Thread Jannis
with recover? The handling looks very much the same as browsing dum.frame objects. Cheers Jannis On 24.07.2012 16:25, Henrik Singmann wrote: Dear Jannis, is there any specific reason you use dump.frames instead of recover? As far as I see it, options(error = recover) would allow to access the

[R] dump.frames and global environment

2012-07-24 Thread Jannis
plot(d) The only way I found is wrapping a function around the lines of code but this would mean changing a lot of code. Any Ideas? Cheers Jannis > sessionInfo() R version 2.14.1 (2011-12-22) Platform: x86_64-unknown-linux-gnu (64-bit) __

[R] time zones and the chron to POSIXct conversion

2012-06-15 Thread Jannis
7;12/12/2000'), tz = 'UTC') Only the code below would give me a POSIXct object with the correct time zone: as.POSIXct(as.POSIXlt(chron('12/12/2000'), tz = 'UTC')) Is this a bug or desired behaviour? Thanks a lot Jannis _

Re: [R] day of the year for chron objects

2012-06-08 Thread Jannis
The following appears to be pretty "standard" (though not included in chron) to me: b = ISOdate(2001,12,12) format(b, '%j') or is that what you refer to with "I know I can make my own using julian" ? No idea about the other questions though ... Jannis On

[R] do.call(), browser() and large arguments

2012-06-08 Thread Jannis
found a similar discussion here: http://tolstoy.newcastle.edu.au/R/help/06/02/21727.html but it stopped before giving me any hint on how to solve the problem or whether there is a solution at all. Any ideas? Thanks Jannis __ R-help@r-project.org

[R] transfer R objects back to console/command line

2012-05-16 Thread Jannis
rgs()[4]) b <- as.numeric(commandArgs()[5]) c=a*b Is ther any way to acess the contents of c in the command line after running R ? Cheers Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the p

[R] problem with assign and get

2012-02-27 Thread Jannis
1:10, 1:10) : target of assignment expands to non-language object What could be a way to get this to work? thanks a lot Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.

[R] test for condition during whole r session or after each command

2012-01-11 Thread Jannis
backtrace the condition or situation that actually created the error. Any ideas? Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and

Re: [R] unexpected behaviour of sub() / usage of regexp

2011-12-09 Thread Jannis
. By the way, is there an easily accessible and search able list of such bugs for R (just for the future)? Thanks a lot Jannis - Ursprüngliche Message - Von: Sarah Goslee An: Duncan Murdoch Cc: Jannis ; "r-help@r-project.org" Gesendet: 15:37 Freitag, 9.Dezember 2011 B

[R] unexpected behaviour of sub() / usage of regexp

2011-12-09 Thread Jannis
tute 1 (minimum) or up to 2 (maximum) digits, i.e. numbers and not the 'e' in the string. Do I misinterpret something here? Thanks for any ideas Jannis > sessionInfo() R version 2.14.0 (2011-10-31) Platform: i686-pc-linux-gnu (32-bit) locale:  [1] LC_CTYPE=en_US.UTF-8   LC_NUM

[R] installing several versions of R (2.14 and 2.12.2) on the same system on Ubuntu

2011-12-05 Thread Jannis
of the R script seems arkward to me but I did this to easily run "R-2.12.2" or "R-2.14" from the command line. Does anybody have any advice on how to fix this stuff? Thanks for your help! Jannis __ R-help@r-project.or

Re: [R] content of global environment with dump.frames()

2011-11-24 Thread Jannis
in case there is no error which causes R to stop. Thanks, however, for your reply! Jannis On Thu, Nov 24, 2011 at 12:52 PM, Jannis wrote: Dear R users, I am using dump.frames() to investigate the content of the different environments in cases of errors or during certain steps of a non

[R] content of global environment with dump.frames()

2011-11-24 Thread Jannis
to use in my case but I could not (yet) figure out how to mimic the convenient behaviour of dump.frames() to save the whole call stack. Thanks for any advice Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEAS

Re: [R] Foreach (doMC)

2011-10-21 Thread Jannis
this post for not beating the dead horse? Thanks anyway, Jay, for your detailed explanations of the origin of these R packages! Best Jannis On 10/21/2011 02:34 AM, Jay Emerson wrote: Jannis, I'm not complete sure I understand your first point, but maybe someone from REvolution will

Re: [R] Foreach (doMC)

2011-10-20 Thread Jannis
for everybody devoting his time to open source software! Jannis On 10/19/2011 01:26 PM, Jay Emerson wrote: P.S. Is there any particular reason why there are so seldom answers to posts regarding foreach and all these doMC/doSMP packages ? Do so few people use these packages or does this have

Re: [R] Foreach (doMC)

2011-10-18 Thread Jannis
ould suggest you try to restrict yourself to saving single vectors from each foreach loop for the sake of simplicity. I myself tried to save different types of R objects from foreach iterations once and it was a hard fight against the code HTH Jannis P.S. Is there any particular reason

Re: [R] help with regexp

2011-10-06 Thread Jannis
Thanks to all who replied! With all these possible solutions it will be hard to find the best one :-). --- Gabor Grothendieck schrieb am Mi, 5.10.2011: > Von: Gabor Grothendieck > Betreff: Re: [R] help with regexp > An: "Jannis" > CC: r-h...@stat.math.ethz.ch > Da

[R] help with regexp

2011-10-05 Thread Jannis
f$', '', sub('^filename_[[:digit:]]_', '' , test)) but this tends to become cumbersome and I was wondering whether there is a more elegant way to do this? Thanks for any help Jannis __ R-help@r-project.org m

Re: [R] remove elements from matrix

2011-09-30 Thread Jannis
Try this. As you did not supply a reproducible example my code is untested: 1.m.vector[index.vector] <- NULL or new.1.m.vector <- 1.m.vector[- index.vector] Someting equivalent is possible for the matrix. HTH Jannis On 09/30/2011 11:30 AM, Alaios wrote: Dear all, I have a numeric

Re: [R] dump.frames, debugger and the "..." argument

2011-09-28 Thread Jannis
f Brian Ripley > Betreff: Re: [R] dump.frames, debugger and the "..." argument > An: "Duncan Murdoch" > CC: "Jannis" > Datum: Mittwoch, 28. September, 2011 15:40 Uhr > On Wed, 28 Sep 2011, Duncan Murdoch > wrote: > > > On 28/09/2011 9:59 A

[R] dump.frames, debugger and the "..." argument

2011-09-28 Thread Jannis
nment I get the following error message: Error in get(.obj, envir = dump[[.selection]]) : argument "..." is missing, with no default Some googleing showed that this seems to be a more common problem but I was not able to find any solution. Any ideas? Jannis ___

Re: [R] invalid strings while parsing code with inlinedocs package.skeleton.dx()

2011-09-08 Thread Jannis
case anybody is digging for the same solution ;-) Jannis On 09/08/2011 11:18 AM, Jannis wrote: Dear list members, I use the package inlinedocs to create documentation for a package that I am building. The function package.skeleton.dx() is used to convert the source *.R file into the *.Rd

Re: [R] several functions in one *.R file in a R package

2011-09-08 Thread Jannis
something wrong here? Thanks Jannis On 09/06/2011 04:46 PM, Duncan Murdoch wrote: On 11-09-06 10:26 AM, Jannis wrote: Dear list members, i have build a package which contains a collection of my frequently used functions. To keep the code organized I have broken down some rather ext

[R] invalid strings while parsing code with inlinedocs package.skeleton.dx()

2011-09-08 Thread Jannis
w wise but the function quickly branches into a complex nesting of other functions. Thanks for any advice! Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.o

Re: [R] subsetting tables

2011-09-06 Thread Jannis
Sorry If I miss the point you want to achieve, but why not just: which(red > 0.5) or red[which(red > 0.5)] if you want to use this col/row wise you could do: apply(red, 1, function(x)x[x>0.5]) and apply(red, 1, function(x)x[x>0.5]) ? --- netzwerkerin schrieb am Di, 6.9.2011: > Von: netz

[R] several functions in one *.R file in a R package

2011-09-06 Thread Jannis
quot; Manual I expected this to work. When I load the package, however, I get the error message that the sub-functions could not be found. Manually sourcing all files in the /R directory however yields the expected functionality. In what way am I mistaken he

[R] get arguments passed to function inside a function

2011-09-01 Thread Jannis
entries with the values of the respective objects but I could imagine that there is already something ready made in R to achieve this. Does anybody have an idea? Thanks Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r

Re: [R] having trouble extracting week from chron object

2011-08-30 Thread Jannis
Well, there is no function called "weeks" in chron. Funny that the help mentions it. You can, however, use normal POSIXct objects and extract the week with: dts <- dates(c("02/27/92", "02/27/92")) dts.posx <- as.POSIXct(dts) result <- as.integer(form

Re: [R] Saving a graph

2011-08-30 Thread Jannis
reads with detailed description. There are numerous solutions and most of them point into Dieters or Brian Ripleys directions. Jannis --- Dieter Menne schrieb am Di, 30.8.2011: > Von: Dieter Menne > Betreff: Re: [R] Saving a graph > An: r-help@r-project.org > Datum: Dienstag, 30.

Re: [R] a question on list manipulation

2011-08-05 Thread Jannis
toupper()/tolower() are the functions to convert the letters. lapply() can be used to apply this to different list elements and names() is helpfull to convert the names of your list. HTH Jannis On 08/05/2011 06:05 PM, zhenjiang xu wrote: Hi R users, I have a list: x $A [1] "a

Re: [R] excel dates and times in R

2011-08-05 Thread Jannis
Well, strptime is certainly the way to go. You did not provide any reproducible example so i can just roughly point out the way to go: 1: combine the two colums to one with paste(,collapse='_') 2: strptime() with the corresponding formats (like "%d-%b-%Y_%H:%M:%S" or simila

Re: [R] fit a 2-variables function to data

2011-08-05 Thread Jannis
you would have found many helpful tutorials. HTH Jannis On 08/05/2011 02:40 PM, Paola Lecca wrote: Dearl all, I have to fit a function y = f(x1, x2) to data experiemntal data describing the measured behavior of y. x1 and x2 are the independent variables. Could you suggest me wich R package

Re: [R] Scatter plot in R

2011-08-05 Thread Jannis
This is a really basic question that is answered in many R tutorials. Why dont you just google: "R import csv" And the first hit will tell you straight away what to do? Jannis P.S. I just guessed from your not very specific post that you may want to import from csv ... On 08/

Re: [R] General indexing in multidimensional arrays

2011-08-04 Thread Jannis
Your function only works for the first dimensions (e.g. indices indicating the positions in the first two dimensions in datacube), correct? Otherwise it looks very handy! And certainly more elegent than my function monster! Jannis On 08/04/2011 09:58 PM, R. Michael Weylandt wrote: Hi

Re: [R] General indexing in multidimensional arrays

2011-08-04 Thread Jannis
Thanks, Gene, for your hint! I indeed did not check any possible situation and my function was not returning what I intened it to return. This updated version, however, should. I am sure there are much easier ways (or ready made functions) to do the same. ind.datacube = function( ##title<< c

Re: [R] General indexing in multidimensional arrays

2011-08-04 Thread Jannis
gested behaviors, you could put in a is.null(Insert) option that returns the desired subset of values. I haven't tested it completely, but for a few sample inputs, it seems be do as desired. Michael On Wed, Aug 3, 2011 at 5:00 PM, Jannis wrote: Thanks for all the replies!Unfortunately the s

Re: [R] General indexing in multidimensional arrays

2011-08-03 Thread Jannis
where Matlab actually is slightly easier to use than R. Thanks for your help! Jannis On 08/01/2011 05:50 PM, Gene Leynes wrote: What do you think about this? apply(data, 3, '[', indices) On Mon, Aug 1, 2011 at 4:38 AM, Jannis wrote: Dear R community, I have a general question

[R] syntax with do.call and `[`

2011-08-03 Thread Jannis
(test,2,)) result = do.call(`[`,list(test,2,'')) How can I use the do.call in that way with leaving the second indexing vector blanc? Cheers Jannis __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE d

[R] General indexing in multidimensional arrays

2011-08-01 Thread Jannis
esult <- data[rep(as.vector(indices),times=4)] but this seems rather complicated and also depends on the order of the dimensions I want to extract. I do not want R to copy Matlabs behaviour, I am just wondering whether I missed one concept of indexing in R?

Re: [R] "inside" argument in barplot

2011-07-29 Thread Jannis
Why dont you plot a stacked barplot with the two values for each depth (or whatever is on the x axis) besides each other? Another option would be to add transparency to the fill color of the plot (col=rgb(1,1,1,0.5)). On 07/29/2011 05:21 PM, Colin Bergeron wrote: Thanks Jannis, I am

Re: [R] HIRHAM netcdf files

2011-07-29 Thread Jannis
seem to be "normal" geographical coordinates. Just extract them and you should have your grid. A really quick and dirty hack would be to use ncrename to rename the dimensions into lat/long Jannis P.S. I always wondered why the following made it into the posting guide: When respo

Re: [R] "inside" argument in barplot

2011-07-29 Thread Jannis
the x/y limits of the two plots to be identical. HTH Jannis On 07/29/2011 04:29 PM, Colin Bergeron wrote: Dear list, I want to plot a sample depth curve over a barplot. It would be perfect if the argument "inside" in the barplot function would be functional, cause I could just add

Re: [R] HIRHAM netcdf files

2011-07-29 Thread Jannis
posting the result of: ncdump -h would help us to understand what kind of data you use. Jannis On 07/29/2011 04:44 PM, Ana wrote: Can someone help me out with a "small" problem? I've started using netcdf files recently, and I want to extract the grid id and also the coordinate

Re: [R] coordinates from locator function in POSIXct format

2011-07-29 Thread Jannis
would have been redirected to as.POSIXct() which converts all sorts of objects to POSIXct. I would expect this function to return your desired format if you feed it with the numeric values that locator() returned. HTH Jannis On 07/29/2011 03:40 PM, cristabel.du...@waldbau.uni-freiburg.de wrote

[R] determining system time for sequence of commands

2011-07-23 Thread Jannis
the whole function. The only (cumbersome) way I figured out would be to run system.time for each individual command. Does anybody have a hint on a function/package that allows to do this automatically? Thanks a lot Jannis __ R-help@r-project.org

[R] graphic problem: transparent window when starting mtrace() from package debug

2011-07-23 Thread Jannis
about the possible cause of the problem? Thanks for your help Jannis P.S. Posting to the Statet mailing list did not yield any helpful advice. My system settings are: WinXP R version 2.12.0 (2010-10-15) Platform: i386-pc-mingw32/i386 (32-bit) locale: [1] LC_COLLATE=English_United States.1252

Re: [R] including figures in html documentation/help

2011-07-06 Thread Jannis
code from the sourcecode of the function directly into the Rd files but I am sure some googeling will help me :-). Thanks again for the help! Jannis --- Duncan Murdoch schrieb am Mi, 6.7.2011: > Von: Duncan Murdoch > Betreff: Re: [R] including figures in html documentation/help > An

Re: [R] including figures in html documentation/help

2011-07-06 Thread Jannis
Thanks for your advice Duncan. In which file should I put the \figure{} command? I tried the *.Rd file, but the html files created are without the figure. Are you sure I only need to include the filename and no path? Jannis --- Duncan Murdoch schrieb am Mi, 6.7.2011: > Von: Duncan Murd

  1   2   3   >