Displaying 20 results from an estimated 800 matches similar to: "Plot of 3d stock price density"
2013 Jun 25
1
Correct scaling of axis in persp3d plot
Hi,
I want to format my axis in my persp3d plot.
With my data, which I attached I created a persp3d plot with the following code, which I summarized from different code snippets I found:
library(rugarch)library(rgl)library(fGarch)fd <-as.data.frame(modelfit,which ='density')color <-rgb(85,141,85,maxColorValue=255)x <-seq(-0.2,0.2,length=100)y <-c(1:2318)f
2012 Dec 17
2
How to get transparent colors to sum to complete opacity?
Dear List,
I want to use transparency in R to represent downweighting of
observations based on clusters (repeated observations in a dataset).
Some clusters will have identical covariate values in a parameter space
-- in the 2D x,y case, these represent a bunch of semi-tranparent dots
in the same place. I'd like these overlapping dots to be completely
opaque. In other cases, the
2011 Aug 09
1
Transparent color ramp problem
Hello,
I can't seem to add transparency to any color ramp I create using colorRampPalette(). Can someone tell me if it is possible to create transparent colour ramps?
I am attempting to map shaded relief under elevation data. I know I can use the terrain.colors() with the alpha option, but I would prefer to create my own colour ramp using more vibrant colours.
My most recent attempt at
2008 Mar 01
1
jpeg and margin text
Hi guys,
I use R 2.6.2 and Windows XP.
I’ve got the following question: I wrote a lot of text into the margin of a
plot. When I use the “jpeg”-function, only a little part of the margin text
is displayed in the final jpeg? Any ideas to change it?
Source-Code:
datenbankdaten<-data.frame(LETTERS[1:20],
2008 Nov 04
2
ggplot & annotating charts
Dear "R-listers"
I've been trying to figure out how to annotate charts in ggplot (ie add text
to line charts, highlighted boxes etc). By and large, I can get close to
what i want with base graphics, but would ideally like to use ggplot
whenever possible (additionally, i would like to add text labels
automatically to the chart). The code is below
I suspect I need to use geom_rect,
2012 Sep 25
3
Plotting of regsubsets adjr2 values not correct
Hi,
I want to make model selection with regsubsets. My code is:
a<-regsubsets(Gesamt ~ CommunistSocialist + CountrySize + GNI + Lifeexp +
Schoolyears + ExpMilitary + Mortality +
PopPoverty + PopTotal + ExpEdu + ExpHealth, data=olympiadaten, nbest=2)
summary(a)
plot(a,scale="adjr2")
(output attached)
The problem is now, that I want to fit the best model again "manually"
2008 May 29
1
Joining uneven datasets
Hello,
I have quite a simple problem that I believe can be solved quite easily. I
have a dataframe as such:
Symbol Date Time Exchange TickType ReferenceNumber Price Size
1 3:YMZ7.EC 12/03/2007 08:30:00 EC B 83916044 13387 9
2 3:YMZ7.EC 12/03/2007 08:30:00 EC A 83916045 13388 1
3 3:YMZ7.EC 12/03/2007 08:30:00 EC B 83916054
2007 Jun 12
2
Stock Price Correlation to Index Price Levels
Hi,
This is probably trivial to most people out there, but I'm struggling with this.
I have a data set which contains the closing prices (properly adjusted for dividends and splits) for several hundred securities and the closing prices for a general stock market index (S&P 500). I have no problem getting it into R with RODBC and manipulating it. There are no missing values. I can
2009 Mar 08
1
fill the space between to lines
hi,
the code below produces me two curved lines.
Now I want to fill the space between these curves with a color and I
don't have any idea how to do that with R.
I tried it with the polygon() function but it didn't worked out.
Can someone her give me a hint on that?
thanks!
x1 <- c(0.0,0.1,0.2,0.3,0.4,0.5,0.6,0.7,0.8,0.9,1.0,1.1,1.2,1.3,1.4,
2024 Dec 30
1
Citation for stock price data from Quantmod
Hello!
Happy Holidays!
I have a question about citing stock price data downloaded via Quantmod,
please. Of course, I will cite Quantmod. Do I also need to cite Yahoo
Finance as the actual source of the data, please?
Also, I'm not sure if this is a question for the Finance sig, but thought I
would start here.
Thank you.
Erin Hodgess, PhD
mailto: erinm.hodgess at gmail.com
[[alternative
2011 Feb 08
1
Simulation of Multivariate Fractional Gaussian Noise and Fractional Brownian Motion
Dear R Helpers,
I have searched for any R package or code for simulating multivariate
fractional Brownian motion (mFBM) or multivariate fractional Gaussian noise
(mFGN) when a covariance matrix are given. Unfortunately, I could not find
such a package or code.
Can you suggest any solution for multivariate FBM and FGN simulation? Thank
you for your help.
Best Regards,
Ryan
-----
Wonsang You
2012 Sep 24
2
add lowess predicted line to scatter plot
Hi,
I have a scatter plot of the variables GNI and Lifeexp (Gross National
Income and Life Expectancy, both metric). So I plotted them and I want to
add a regression line and a lowess line. I use lowess and not loess because
I have missing values. My code:
plot(GNI,Lifeexp)
abline(lm(Lifeexp~GNI), col="red")
y.loess<-loess(Lifeexp~GNI,na.
action = na.exclude)
2004 Dec 10
1
Adding a polygon to a time series plot
Preamble: Sorry for being dense.
Now that that's done, here are my questions.
I want to put a polygon on a plot of a time series. I'm going to add lines
from a smooth.spline interpolation and other annotation to it. But here's
the general idea:
# Start code
n <- 121
dat <- rnorm(n)
plot(dat, type="n")
polygon(c(1:n,n:1), c(dat,c(rep(0,n))), col =
2006 Mar 03
1
Fractional brownian surfaces
Hi list,
I'm trying to generate fractional brownian surfaces in R.
[A detailed description with respect to various techniques to generating
these neutral landscapes has been described by Timothy Keitt (spectral
representation of neutral landscapes, Landscape Ecology, 2000) and
probably various other authours.]
Are there any packages that deal with this or related items? I've been
2008 Jul 23
6
Convert list of lists <--> data frame
For a function that takes an argument as a list of lists of parameters,
I'd like to be able to convert that
to a data.frame and vice versa, but can't quite figure out how.
pats <- list(structure(list(shape = 0, shape.col = "black", shape.lty = 1,
cell.fill = "white", back.fill = "white", label = 1, label.size = 1,
ref.col = "gray80",
2010 Nov 19
2
simple loop problemo (Geo brownian motion)
I would like to plot multiple random walks onto the same graph. My p
variable dictates how may random walks there will be.
par(mfrow=c(1,1))
p <- 100
N <- 1000
S0 <- 10
mu <- 0.03
sigma <- 0.2
nu <- mu-sigma^2/2
x <- matrix(rep(0,(N+1)*p),nrow=(N+1))
y <- matrix(rep(0,(N+1)*p),nrow=(N+1))
t<- (c(0:N))/N
for (j in 1:p)
{
z <- rnorm(N,0,1)
x[1,j] <- 0
y[1,j]
2007 May 31
0
adehabitat version 1.6
Dear all,
I have just uploaded to CRAN the version 1.6 of the
package 'adehabitat'. Significant changes are
listed below:
* The package has been reorganized into four parts (see
?adehabitat-package for a description): (i) management of raster maps,
(ii) habitat selection / ecological niche analysis, (iii) home range
analysis, and (iv) analysis of animals trajects. The package contains
2007 May 31
0
adehabitat version 1.6
Dear all,
I have just uploaded to CRAN the version 1.6 of the
package 'adehabitat'. Significant changes are
listed below:
* The package has been reorganized into four parts (see
?adehabitat-package for a description): (i) management of raster maps,
(ii) habitat selection / ecological niche analysis, (iii) home range
analysis, and (iv) analysis of animals trajects. The package contains
2010 Mar 10
0
Color facets by z-level (solved by creating example)
I am having trouble getting my facets colored with "concentric" colors
by z level. This code give a fair representation of my problems
dealing a real dataset
cmtx <- matrix(, nrow=10, ncol=10)
cc <- (row(cmtx)-5)^2 + (col(cmtx)-5)^2
cc
#----------
[,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10]
[1,] 32 25 20 17 16 17 20 25 32 41
[2,]
2009 Apr 03
2
Geometric Brownian Motion Process with Jumps
Hi,
I have been using maxLik to do some MLE of Geometric Brownian Motion Process and everything has been going fine, but know I have tried to do it with jumps. I have create a vector of jumps and then added this into my log-likelihood equation, know I am getting a message:
NA in the initial gradient
My codes is hear
#
n<-length(combinedlr)
j<-c(1,2,3,4,5,6,7,8,9,10)