Dear all,
version 1.2-2 of package NMOF is on CRAN now.
NMOF stands for 'Numerical Methods and Optimization
in Finance'. The package provides R code and datasets
for the book with the same name, written by Manfred
Gilli, Dietmar Maringer and Enrico Schumann, published
by Elsevier/Acad
am now putting in it the package. Not a problem. But the
> problem is the help file. What is the best way to generate a help file
> "after the fact" like that, please?
>
> Thank you in advance. Hope everyone is enjoying various holidays.
>
> Sincerely
ownload the complete
site. It is usually available by default on Unix-style
systems; I am sure there is a version for Mac. If you
insist on using R, you could write a simple wrapper,
using ?system or ?system2.
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
___
o read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE a
build (i.e. a complete version, not just
the patch) is available from the same CRAN site at
which you find the official release; just further
below.
> -----Original Message-
> From: Enrico Schumann [mailto:e...@enricoschumann.net]
> Sent: Friday, February 02, 2018 10:36 AM
> To
entation. (Presumably, this is used in
> nlm, too; alas, nlm is in C, not native R.) regards, /iaw
>
There is a 'bracketing' function in package NMOF,
though it is for root-finding (i.e. for optimising you
would need the derivative).
--
Enrico Schumann (the maintai
.01 15720.61
## 2017-12-07 08:41:00 17600.00 15770.00
## 2017-12-07 08:42:00 17593.00 15750.00
## 2017-12-07 08:43:00 17630.01 15770.00
See Ripley, B. D. and Hornik, K. (2001) Date-time
classes. R News, 1/2,
8–11. https://www.r-project.org/doc/Rnews/Rnews_2001-2.pdf
--
Enrico Schumann
Luce
est <- "hello\n1"
regexpr(".*[0-9]", test)
## [1] 1
## attr(,"match.length")
## [1] 7
## attr(,"useBytes")
## [1] TRUE
regexpr(".*[0-9]", test, perl = TRUE)
## [1] 7
## attr(,"match.length")
## [1] 1
## att
, 1)))
this cause the 0 value.
How can I use it to get my minimization value using tabu search in R ?
Thanks .
If you want people to help you, provide a minimal (or, at least, small)
reproducible code example. In particular, tell people what package(s)
you are using.
--
Enrico Schumann
st to also look at heuristic algorithms that can
deal with such problems (e.g. genetic algorithms).
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://st
luck)
Enrico Schumann
[*] Which does not mean it has not found it.
I will take a look at that page, thanks! Hopefully there is an R
implementation of generic B&B as I described out there somewhere...
Alex Byrley
Graduate Student
Department of Electrical Engineering
235 Davis Hall
(716) 341-1
Francesca Pancotto, PhD
Use ?grep or ?grepl:
df[grep("strat", row.names(df)), ]
(in which 'df' is your data frame)
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-hel
)
>
> I tried it with the following code, but that doesn't work.
>
> data4.1<-data3[data3$ORDER%in% "[(]*->*[)]",]
>
> maybe anyone can help me.
>
> Thank you.
>
> Best regards
>
> Mat
>
Try ?grepl instead of %in%.
x <- c("for
rep(wmin, na))
result <- solve.QP(Dmat = 2*cov(R),
dvec = rep(0, na),
Amat = t(A),
bvec = bvec,
meq = 2)
w <- result$solution
## check results
sum(w) ## check budget constraint
sum(w[1:5])## chec
week starts ends
1 2010-08-21 33 2010-08-16 2010-08-22
2 2016-08-01 31 2016-08-01 2016-08-07
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.et
etworks.imdea.org/people/~luis_nunez/
>
> On 09/08/2016 12:13 PM, Veronica Andreo wrote:
>
> Hello list,
>
> Is there a quick way to get start and end date (%Y-%m-%d) from ISO
> weeks if I only have dates?
>
ace (and not attached):
> [1] compiler_3.3.1 tools_3.3.1
>>
>
> __
> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-proj
lly faster to first extract the component of
interest, i.e. the specific column, and then to subset
this vector. The result will, of course, be a vector,
not a data.frame.)
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@
match(x, v)' is what you want? In which 'x' may be a vector of
length > 1.
In any case, have you actually tried package 'fastmatch'? The function
'fmatch', which that package provides, is very fast for repeated
lookups in a table 'v'.
--
Enrico Schum
ciated.
>
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
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, repro
in 1:nrow(myMatrix)) {
for(i in 1:ncol(myMatrix)) {
myMatrix[i,i] = -1
myMatrix[i,i+1] = 1
}}
print(myMatrix)
Thanks in advance!
Perhaps you do not need loops at all?
myMatrix <- matrix(0, 5, 12)
diag(myMatrix) <- -1
diag(myMatrix[, -1]) <- 1
--
Enrico Schuman
9])[ \\.\\)-].*", "\\1",
subtext) # return 2010
but
subtext <- "bla 1010 bla"
sub(".*[ \\.\\(-]([12][01289][0-9][0-9])[ \\.\\)-].*", "\\1",
subtext) # return 1010
I would like exclude the case 1010 and other like this.
The solution would be:
s it possible without any additional package ?
>
>
> Kind Regards Knut
>
Like so?
start <- "23:01:18"
Y <- 1:5
tmp <- as.POSIXct(paste(Sys.Date(), start))
tmp <- tmp + seq(from = 0, length.out = length(Y))
format(tmp, "%H:%M:%S")
tance need
less space (and if you sort the input data by
median, say, they often help much better to see
differences between samples); or use similar plots such
as quartile plots
(e.g. https://cran.r-project.org/web/packages/NMOF/vignettes/qTableEx.pdf ).
kind re
his gives: [1] "Apr 2019".
CB> How can I extract the full name ie. 'April 2019'
CB> Appreciate your pointer. Thanks,
library("zoo") ## where 'as.yearmon' comes from
format(as.yearmon(Sys.Date()), "%B %Y")
## [1] "Ap
other strings
> have more or fewer parts separated by '-'. Is there a general way to do it?
> Thanks.
>
> Jun
This should work for your example:
gsub(".*-([^-]*)$", "\\1", test)
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
___
; subLogLike <- 0; bestTemp <- 0; bestDelta= 0;
>
> min = 0.001; max = .5; inc = 0.001;
> deltaList = seq(min, max, inc)
> mina = 0; maxa = 5; inca = .01
> amList = seq(mina, maxa, inca)
> maxLogValue <- -1000
> for(delta in deltaList){
> for(temp in amL
> Thank you for your attention and your help
> Stefano
strptime creates a POSIXlt object, and the specified format
tells it how to interpret the string you pass in. (Your
factor is converted to character by strptime.)
If you want to have the POSIXlt object printed in a
particular way, use ?s
Mac
> bryanmac...@gmail.com
>
A tutorial on how to run such regressions is included
in the NMOF package.
https://cran.r-project.org/package=NMOF/vignettes/PSlms.pdf
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-p
;manually' an LMS-regression, i.e. how to do
the actual optimisation.
>
>> On Oct 8, 2016, at 6:17 AM, Enrico Schumann wrote:
>>
>> On Sat, 08 Oct 2016, Bryan Mac writes:
>>
>>> Hi R-help,
>>>
>>> How do you perform least median squa
how to manage the
> formatting part though, so that the 1-pager output looks decently
> presentable. Thanks.
>
> Regards,
> Preetam
If using LaTeX is an option, I would suggest
?Sweave. There are many tutorials on the web that
should get you started.
--
Enrico Schumann
Lucerne, Switz
Dear all,
version 0.40-0 of package NMOF is on CRAN now, 5 years
(exactly) after its first release on CRAN.
'NMOF' stands for 'Numerical Methods and Optimization
in Finance'. The package accompanies the book with the
same name, written by Manfred Gilli, Dietmar Maringer
UE)
for (i in seq_len(nrow(df)))
assign(df[i, "Symbol"], df[i, "Value"])
But depending on what you want to do, it may be
cleaner/safer to keep the variables from the table
together in a list.
tbl <- as.list(df[["Value"]])
variable (and tilde expansion will be
| performed). If this is unset, a file called
| ‘.Rprofile’ is searched for in the current directory
| or in the user's home directory (in that order). The
| user profile file is sourced into the workspace.
`
--
Enrico Schumann
Lucerne, Switzerland
ds"
But maybe I am completely misunderstanding what you
mean
Kind regards
Enrico
>
>
>> On Mar 24, 2017, at 3:48 AM, Enrico Schumann wrote:
>>
>> On Thu, 23 Mar 2017, Bruce Ratner PhD writes:
>>
>>> Hi R'ers:
>>> I wou
rl = {https://www.R-project.org/},
## }
##
## We have invested a lot of time and effort in creating R, please cite it
## when using it for data analysis. See also ‘citation("pkgname")’ for
## citing R packages.
kind regards
Enrico
--
Enrico Schumann
Lucer
this on the fredr information package and
> was wondering if anyone here might know?
>
Just for completeness: there is also the 'alfred' package
(https://cran.r-project.org/package=alfred), with which
you can also access data of the St. Louis Fed.
--
Enrico Schumann
Lucerne, Swi
66608+59387.
> However it is 681193 which is less that number of elements in s1!
>
>> length(base::union(s1, s2))
> [1] 681193
>
> Any hints?
>
> Regards
> Martin
>
Duplicates?
kind regards
Enrico
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
;, tz="CEST")
>>> # [1] "2021-04-21 CEST"
>>> as.POSIXct("2021-04-21 00:00:00")
>>> # [1] "2021-04-21 CEST"
>>>
>>> all representations on my system are the same, why is the plot location
>>> of the arrows different??
>>> I am
3.8
> generics_0.1.0
> [10] ellipsis_0.3.2 tools_4.1.0 glue_1.4.2 purrr_0.3.4
> compiler_4.1.0 pkgconfig_2.0.3 tidyselect_1.1.1 tibble_3.1.2
>
>
>
>
>
>
>
> --
> Federico Calboli
> LBEG - Laboratory of Biodiversity and Evolutionar
rsplit(s, "[-]")
year <- as.numeric(sapply(tmp, `[[`, 1))
valid.year <- year < 2500 & year > 1800
month <- as.numeric(sapply(tmp, `[[`, 2))
valid.month <- month >= 0 & month <= 12
day <- as.numeric(sappl
ng for:
A <- 42
get("A")
## [1] 42
> Thank you,
> Yours sincerely,
> AKSHAY M KULKARNI
>
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and m
018-06-18 12:00:00 CEST"
Note that the times differ: the numbers are probably
not /displayed/ to full precision in R.
You may also want to search the archives of this list,
as this question has been discussed before.
--
Enrico Schumann (maintainer of package datetimeutils)
Lucerne, Swit
nvisible(NULL)
}
(which is essentially taken from 'str.data.frame').
Then:
class(iris) <- c("data.frame.oneline", class(iris))
str(iris)
## 'data.frame': 150 obs. of 5 variables
str(list(a = 1,
list(b = 2,
5 digits.
>
> I don't understand this error because the equivalent commands for another
> data source file completes without error.
>
> What is that error message telling me?
>
> TIA,
>
> Rich
>
There is no column 'ht'.
--
Enrico Schumann
Luce
lt;- data.frame(a = 1:5)
df$b <- as.numeric(df$b)
## Error in `$<-.data.frame`(`*tmp*`, b, value = numeric(0)) :
## replacement has 0 rows, data has 5
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-hel
if(length(npos[[1]]) == 0) return(character(0));
> strip.FUN = if(strip) {
> function(id) {
> if(npos[[1]][[id]] + 1 < npos[[2]][[id]]) {
> nStart = npos[[1]][[id]] + 1;
>
age d'avis :
> Dans qbeta(p = c(0.025, 0.975), shape1 = 3.3108797, shape2 = 1e-07) :
> qbeta(a, *) =: x0 with |pbeta(x0,*) - alpha| = 0.024997 is not accurate
>
Try 'suppressWarnings'.
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
i, Dietmar Maringer and Enrico
Schumann.[1]
Since the last announcement on this list, functionality has
been added to the package, e.g. for computing minimum-CVaR
and tracking portfolios, or downloading IPO data. See the
NEWS file [2] for all changes. The documentation has also
been expanded.
haps also of interest:
https://github.com/matloff/R-vs.-Python-for-Data-Science
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r
d: you'd probably get
better answers if you ask more specific questions,
e.g. why/for what application you want to use LMS.
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and
your TeX
distribution provides.
If this is a vignette, you can specify a Makefile, see
https://cran.r-project.org/doc/manuals/R-exts.html#Writing-package-vignettes
>
>
> [[alternative HTML version deleted]]
>
> __
>
within R.
>
> QUESTION
> Is it possible within R to define the line ending aspect of file output?
>
>
> Kindest Regards,
Just a remark: there is a "standard" for CSV,
https://datatracker.ietf.org/doc/html/rfc4180.
It always requires C
tp://www.bigelow.org/
>> https://eco.bigelow.org
>>
>
Maybe I have missed it, but could you please show how
you tried to read the table?
When I use your file with
read.table("sample text.txt", header = FALSE, sep = ",")
I get
## V1
pful response here, but generally speaking, this list is
> about R **programming**, and statistical issues/tutorials are off topic.
> You might try
> https://stackoverflow.com/questions/tagged/statistics
> if you don't get adequate help here.
>
b)is there (I can't find
> anything) within R which allows me to monitor the progress of the download,
> if in fact it is taking place?
> Thanks Nick Wray
>
Have you tried 'download.file'? It should provide a
progr
o create the fractions directly:
gmp::as.bigq(n = 0:7, d = 7)
## Big Rational ('bigq') object of length 8:
## [1] 0 1/7 2/7 3/7 4/7 5/7 6/7 1
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-proj
repository. Seems a bit overkill
> (given that wininet has done the trick nicely up to
> now), but at least it works.
>
> HTH.
>
> \Gisbert
There is also the miniCRAN package
(https://cran.r-project.org/package=miniCRAN).
--
Enrico Schumann
Lucerne, Switzerland
http://enricos
gt; How can I switch off any file crippling activity?
FS> Kind regards,
FS> Frank
Do you need 'path.expand'? For example,
readLines("~/Desktop/a ~ b")
reads just fine the content of a file named
'a ~ b' on my desktop.
--
Enrico Schumann
Lucerne, Swi
Quoting Frank Schwidom :
On 2019-06-05 20:32:07, Enrico Schumann wrote:
>>>>> "FS" == Frank Schwidom writes:
FS> Hi,
FS> As I can see via path.expand a filename which contains a
FS> tilde anywhere gets automatically crippled.
FS> +
ointers/ideas:
1) Since you know cron, I suppose you work on a
Unix-like system, and you likely have a programme
called 'wget' either installed or can easily install
it. 'wget' has an option 'mirror', which allows you
to
apply(1:10, f))
## int [1:10] 1 2 3 4 5 6 7 8 9 10
str(sapply(-5:5, f))
## List of 11
## $ : int(0)
## $ : int(0)
## $ : int(0)
## $ : int(0)
## $ : int(0)
## $ : int(0)
## $ : int 1
## $ : int 2
## $ : int 3
## $ : int 4
## $ : int 5
--
Enrico Schumann
Lucerne, Switzerland
http://e
Dear all,
version 2.0-1 of package NMOF is on CRAN now.
NMOF stands for 'Numerical Methods and Optimization in Finance',
and it accompanies the book with the same name, written by
Manfred Gilli, Dietmar Maringer and Enrico Schumann.[1]
The new version of the package provides all
th a correct result class
HW> instead of an error?
HW> Thanks, HW
You should probably use
if (inherits(e, "try-error")) {
# ... do something
}
kind regards
ENrico
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
___
> time zone: Asia/Kolkata
>> tzcode source: system (glibc)
>>
>> attached base packages:
>> [1] stats graphics grDevices utils datasets methods base
>>
>> other attached packages:
>> [1] stargazer_5.2.2
>>
>> loaded via a namespace (and not attached):
>> [1] compiler_
cbind(option.trades, stock.trades[i, ])
## timestamp option.price timestamp stock.price
## 1 2023-08-07 10:23:22 2.5 2023-08-07 10:23:21 102.2
## 3 2023-08-07 10:25:33 2.7 2023-08-07 10:24:57 103.1
## 4 2023-08-07 10:28:41
algo = list(
nP = 100, nG = 500,
min = rep( 5, 5), max = rep( 10, 5)))
ofv.below.threshold[i] <- sol$OFvalue < 1e-6
}
sum(ofv.below.threshold)/length(ofv.below.threshold)
(These 50 runs take less than half a min
- attr(*, ".internal.selfref")=
>
> Thank you for help
>
I'd use something like this:
map <- c(BUY = 1, SELL = -1)
mydf1$side <- map[mydf1$side]
str(mydf1)
## Classes ‘data.table’ and 'data.frame': 1 obs. of 4 variables:
## $ symbo
=suncalc
(but I don't use any of those packages)
Perhaps also worth asking at:
https://stat.ethz.ch/mailman/listinfo/R-SIG-Geo/
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list -- To UN
ame?
>
?flush.console
... but you'll need to print/message/cat/... explicitly in the
loop, or the output won't be shown. [Also, options(warn=1) might
be useful.]
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
_
his reply is late, but you can use raw
strings for the replacement:
gsub("a|b", r"(\\)", "abcdef")
## [1] "cdef"
which might be easier to read, sometimes.
[...]
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
_
ano
>
I think this could be simplified a bit:
a <- as.POSIXct("2002-11-01 09", format = "%Y-%m-%d %H", tz="Etc/GMT-1")
b <- as.POSIXct("2004-06-01 09", format = "%Y-%m-%d %H", tz="Etc/GMT-1")
Create your sequence:
ded nulls
>
> Is there any way to read this data directly onto R?
>
> Thanks for your time
>
The looks like a byte-order mark
(https://en.wikipedia.org/wiki/Byte_order_mark).
Try this:
fn <-
file('https://online.stat.psu.edu/onlinecourses/sites/stat501/files/
;> >> I used this
>> >> gs$d1 = as.Date(as.character(gs$date), format = "%Y-%m-%d")
>> >>
>> >> but I got NA's.
>> >>
>> >> How do I get my desired result?
>> >> Thank you.
>>
merged series, with an attribute 'timestamp',
from which you could create an xts object again.
I am not sure if it is the fastest way, but it's probably faster than calling
merge repeatedly.
kind regards
Enrico (the maintainer of PMwR)
--
Enrico Schuman
T" "1998-01-06 05:00:00 GMT"
[29] "1998-01-06 06:00:00 GMT"
This seems to suggest day 5 and 6 in January 1998 instead of day 1 and
2 in May of 1998.
I have spent some time trying to resolve this but I have not been successful.
I would be thankful if you could help me to ch
6 6480
## 6 98 1 57 6457
The data that you read in has January (1) as month.
So whatever goes wrong, seems to go wrong when you read
the data. Are you quite sure you read the file you
read is the file you have shown?
kind regards
Enrico
Ogbo
Time differences in days
# [1] 0 1 0
That shows that the second date is followed by one missing day.
Duncan Murdoch
But you might want to check if the dates in 'd' are really sorted.
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
___
header = FALSE, sep = " ") -> data
as.POSIXct(paste(as.Date(paste0(data[[1]], "-1-1")) + data[[2]] - 1,
data[[3]]),
format = "%Y-%m-%d %H")
You might want to specify a different timezone, and also check for
"off-by-one" erro
ed Ubuntu (a day or two
later).
Adrien> I hope someone can help.
There has been a discussion on R-SIG-Debian recently,
and /perhaps/ it is related to your troubles.
See https://stat.ethz.ch/pipermail/r-sig-debian/2020-April/003159.html
and in particular
https://stat.ethz.ch/pipermail/r-sig-debia
ing does not specify the date completely,
the returned answer may be system-specific."
So perhaps try something like
as.Date(paste0("01-", "11-1993"), format = "%d-%m-%Y")
## [1] "1993-11-01"
Or look at 'yearmon' i
:3,
b = 4:6)
library("openxlsx")
wb <- createWorkbook()
sheet <- "sheet1"
addWorksheet(wb, sheet)
writeData(wb, sheet = sheet, x = df)
sheet <- "sheet2"
addWorksheet(wb, sheet)
writeDa
3: INCBR0005073131 157705920 itsm-ticket U&FOUO&USA 0
> 4: INCBR0005074186 157705920 itsm-ticket U&FOUO&USA 0
> 5: INCBR0005074188 157705920 itsm-ticket U&FOUO&USA 0
> 6: INCBR0005074546 157705920 itsm-ticket U&FO
13 00:18:00
> 01/10/2013 00:19:00
>
> Thanks for your help!
Since your dates and times are character vectors, you can do this:
substr(Dataset$Time, 7, 8) <- "00"
If you want to treat them as actual dates and times, you need to convert
them into one of R's date/time classes (
ction" looks like. Could you
post a (small) self-contained example?
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://w
On Tue, 23 Jul 2013, Christof Kluß writes:
> Am 23-07-2013 13:20, schrieb Enrico Schumann:
>
>> On Tue, 23 Jul 2013, Christof Kluß writes:
>>
>>>
>>> I have "observations" obs <- (11455, 11536, 11582, 11825, 11900, ...)
>>>
>>>
ion or file name. For ‘base64decode’ it can be
a string or a binary connection."
Try this:
rawToChar(base64decode(base64encode(charToRaw("saf"
## [1] "saf"
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
___
#I tried
>> rollapply and get the error message
>> #"Error in seq.default(start.at, NROW(data), by = by) :
>> # wrong sign in 'by' argument"
>>
>> #example:
>>
>> mymatrix <- ( matrix(data=1:100, nrow=5, ncol=20) )
>> mymatrix_
On Mon, 05 Aug 2013, Qiang Wang writes:
>> On Sat, Aug 3, 2013 at 3:49 PM, Enrico Schumann
>> wrote:
>>
>>> On Fri, 02 Aug 2013, Qiang Wang writes:
>>>
>>> > Hi,
>>> >
>>> > I'm struggling with encode/decode stri
or when time zones are relevant.)
Perhaps something like this:
require("zoo")
plot(merge(a, b), plot.type = "single", yaxt = "n")
midnight <- ISOdatetime(2013, 1, 1, 0, 0, 0, "GMT")
sq <- seq(0, 86400, by = 300)
axis(2, at = sq, label
[i, 4] | var[i,6])
> points(i, var[i, 2], pch=4)
> }
>
> --> the result is displayed in attachment "Plot2.pdf"
>
> The same problem appears if instead of
>
> as.Date(var[, 1], origin="1899-12-30")
>
> I use
>
> var[, 1]
>
> to de
ible code example (as the posting guide asks you
to); otherwise I doubt you will get much help.
In any case, your objective function (OF) should not evaluate to
NaN. The algorithm decides whether one solution is better or worse than
another solution by looking at the OF value. NaN translates into &q
> eps, in which eps is the minimal weight that would be
sufficiently greater than zero in your application.)
> Do I put the right constraints ?
>
> Could you help figure out it. Thanks in advance.
>
> Jiting
>
Regards,
Enrico
--
Enrico Schumann
Lucerne, Switzerland
http://en
)
identical(K3, K1)
##user system elapsed
## 0.132 0.028 0.161
##
##user system elapsed
## 0.024 0.048 0.071
##
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing
the problem?
I doubt it: (h, m) is not a _permutation_ of {h, m, s}.
Enrico
>
> Thanks for all of the help.
>
> Stephen
>
>
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-project.org mailing list
h
tig ist" means that "delta <= 0"
does not evaluate to TRUE or FALSE, but NA.
>
> Thanks a lot for your help!
>
>
> --
> Neumann, Conrad
>
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschumann.net
__
R-help@r-pr
x)
The result is only counterintuitive (or inconvenient, perhaps) in the
special case in which apply is supposed to return an array that has the
same dimension as its input. More generally, you will do something like
apply(test, 1, median)
apply(test, 1, function(x) list(sum = sum(x), valu
") etc. and apply a function to do this in a more automated fasion?
> This would involve using the list value in the directory path to read in
> the file i.e.
Something like this?
files <- dir("my_directory")
for (f in files) {
## do something with file 'f'
}
na.omit(trades(rownames(s), s$Price, s$St)) :
could not find function "trades"
But as others have already pointed out, it is better to '?source' code,
or to use an editor that can push code chunks directly to R.
--
Enrico Schumann
Lucerne, Switzerland
http://enricoschum
On Tue, 28 May 2013, Enrico Schumann writes:
> On Tue, 28 May 2013, Mark Breman writes:
>
>> Hello List,
>>
>> When i paste a large block of R code from an editor to the R command line
>> the execution of the code will often fail at some point because it is
1 - 100 of 156 matches
Mail list logo