Displaying 20 results from an estimated 200 matches similar to: "density plot on a log scale"
2010 Feb 06
1
Why does smoothScatter clip when xlim and ylim increased?
Hi:
Is there a way to get smoothScatter to not clip when I increase the xlim and
ylim parameters?
Consider the following example:
set.seed(17)
x1<-rnorm(100)
x2<-rnorm(100)
smoothScatter(x1,x2)
#Now if I increase xlim and ylim notice that the plot seems to be clipped at
the former xlim, and ylim boundaries:
smoothScatter(x1,x2, xlim=c(-5,5), ylim=c(-5,5))
Thanks.
Jen
sessionInfo()
R
2009 Apr 22
1
reversing xlim, ylim in smoothScatter
Hello,
I have found that in smoothScatter it is not possible to reverse the axes plotted (R version 2.9.0) . It appears that this arises from the hard coding of xlim and ylim in smoothscatter.R in the lines :
x <- x[ xlim[1] <= x[,1] & x[,1] <=xlim[2], ] (line number 25)
and
x <- x[ ylim[1] <= x[,2] & x[,2] <= ylim[2], ] (line number 31)
This results in a x
2011 Jun 10
1
smoothScatter function question and adding a legend
Hello,
I have a few questions, regarding the smoothScatter function.
I have a scatter plot with more than 500,000 data points for
two samples. So, I am wanting to display the density in colors
to convince people that my good correlation coefficient is not
due to an "influential point effect" and plus, I also want to make
my scatter plot look pretty. Anyway ...
I have been able to
2012 Oct 02
5
smoothScatter plot
Hi, I want to make a plot similar to sm1 (attached). The code I tried is: dcols <- densCols(x,y)
smoothScatter(x,y, col = dcols, pch=20,xlab="A",ylab="B")
abline(h=0, col="red")
But it turned out to be s1 (attached) with big dots. I was wondering if anything wrong with my code. Thanks,Zhengyu
-------------- next part --------------
A non-text
2008 Mar 14
1
smoothScatter
Hi, I have been trying to plot density plots using the example on:
http://addictedtor.free.fr/graphiques/graphcode.php?graph=139
I used to use this function, but I cannot get any old code or even the example to work.
library("geneplotter")
require("RColorBrewer")
x1 <- matrix(rnorm(1e4), ncol=2)
x2 <- matrix(rnorm(1e4, mean=3, sd=1.5), ncol=2)
x <-
2009 Jul 26
2
smoothScatter problems
Hello,
I'm having some trouble getting a good result for a smoothScatter plot.
I have some data that I want to log-plot, but when I use smoothScatter
the result is not correct.
The problem seems to be that with the log="x" argument smoothScatter
calculates the bins linearly, so the plot will be skewed towards the right.
See for example:
2008 Sep 22
1
SmoothScatter plot range issue
Hello,
I am attempting to use smoothScatter to plot a heatmap of locations of
events in an x-y axis. When I plot the heatmap without passing xlim and ylim
parameters, it fills the plot area but the perspective is a bit skewed. I
would like to standardize these plots to a uniform window size that does not
depend on the range of values in the dataframe. However, when I resize the
plot using xlim or
2008 Jul 28
1
Is there a way to avoid loading dependendent packages?
Hello R help list
I have been using the smoothScatter function within the "geneplotter"
package to make some graphs using a Sweave Rnw script called via Rscript
in a DOS/Windows batch file. The Rscript will ultimately be called by a
web service with time-out constraints, hence things need to run as
swiftly as possible.
The geneplotter package is currently loaded each time R is invoked
2011 Jul 28
3
smooth scatterplot and geo map
Hello everybody,
I'm trying to understand how to draw a smoothed scatterplot on a geographic
map with R.
Have a dataframe with point locations (long, lat) and was able to simply
plot these points on a shp map by using the maptools package. However,
instead of having simply the raw points on the map, I would like to have a
"smoothed" scatterplot of the same superimposed on the map.
2003 May 28
1
Kernel density
Hi,
I want to fit a kernel density estimator by bkde of library KernSmooth.
I need only the density value at the point 0.
I do not understand the following behaviour:
> q <- rnorm(100)
> bkq <- bkde(q, bandwidth=0.11, gridsize=1, range.x=c(0,0))
Error in 0:L : NA/NaN argument
> bkq <- bkde(q, bandwidth=0.11, gridsize=1, range.x=c(-1,1))
> bkq
$x
[1] -1
$y
[1] NA
> bkq
2005 Aug 10
2
extend question
Is it possible to call the super class''s version of a function from a subclass?
SuperClass = Class.create();
SuperClass.prototype = {
initialize: function(){
this.varA = '''';
this.varB = '''';
}
}
SubClass = Class.create();
SubClass.prototype = (new SuperClass()).extend({
initialize: function(somevar) {
this.somevar = somevar;
}
2011 Aug 09
1
How to pass different arguments to a function within lapply()?
Hi all,
I have a data frame called "rst", see below:
------------------------------------------------------------------------------------------
# This is a paste able example
# In case you don't have "KernSmooth" package installed, please uncomment
below line.
# install.packages("KernSmooth")
library(KernSmooth)
rst <- data.frame(hsp = rnorm(23), dal =
2012 Jul 16
2
about dpik
Thank you for your reply.
I know the x in dpik() means the vector. But I don't know how to import into
c() with a huge metadata (>1000).
Following is my some try, and the h is: [1] 0.001180569, which seems to be
feasible.
2008 Feb 14
1
plot matrix
Dear R users,
I like to plot a matrix A which looks like this:
,1 ,2 ,3 ,4
1, 1 10 100 1000
2, 0.5 0.2 1.0 4.3
3, 0.1 0.2 0.3 0.5
.....
where the 1st row is representing the X-axis values. The subsequent
rows should be plotted on the y-axis. I would prefer to use the
smoothScatter plotting function of the geneplotter package, but to
begin with R I'd be happy to use
2006 Dec 18
2
surface3d grid from xyz dataframe
Hi List,
I am trying to plot a grid with an overlayed height. I have a dataframe
with four variables:
x,y,gridvalue,height. The dataframe has 2.5mio observations (ie grid
points),
I assign colors through the gridvalue using map_color_gradient thus
producing:
x,y,gridvalue,height,gridcol as variables of the dataframe. The grid
dimensions are 1253 x 2001 (=2507253 data points).
My attempts with
2005 Apr 28
1
strange behaviour of importFrom directive in name space
Dear listers,
After activating the name space for my bioconductor package (prada) I
successfully ran R CMD check. However when loading the package in R and
running the examples the imported function brewer.pal from package
RColorBrewer is not found. I can directly call brewer.pal from the
RColorBrewer name space typing RColorBrewer::brewer.pal, but it is not
imported into my prada name space. When
2005 Apr 28
1
strange behaviour of importFrom directive in name space
Dear listers,
After activating the name space for my bioconductor package (prada) I
successfully ran R CMD check. However when loading the package in R and
running the examples the imported function brewer.pal from package
RColorBrewer is not found. I can directly call brewer.pal from the
RColorBrewer name space typing RColorBrewer::brewer.pal, but it is not
imported into my prada name space. When
2011 Jul 02
1
Error when using plot in diag.panel argument of pairs
Dear Madame or Sir,I am having a problem in combining density-smoothed scatterplot matrices with a plot of kernel destiny estimations of each dimension plotted on the respective field of the diagonal.I have tried following approach using the package "sm" for the kernel density estimation, as well as "MASS" respectively:pairs(myTable[, 1:4],panel=function(x,y, ...){
2020 Nov 02
2
[llvm-mc] FreeBSD kernel module performance impact when upgrading clang
Hi,
I'm in the process of migrating from clang5 to clang10. Unfortunately clang10 introduced a negative performance impact. The cause is an increase of PLT entries from this patch (first released in clang7):
https://bugs.llvm.org/show_bug.cgi?id=36370
https://reviews.llvm.org/D43383
If I revert that clang patch locally, the additional PLT entries and the performance impact disappear.
This
2008 Feb 11
2
image quality
dear all,
I am writing a sweave documentation for my analysis, and I am plotting huge
scatter plot data for microarray.
unlucly this take a lot of resource to my pc because of the quality of the
image which is to high (I see the PC get stuck for each single spot).
how can I overcome this problem? is there a way to make lighter image?
john
[[alternative HTML version deleted]]