similar to: Re-binning histogram data

Displaying 20 results from an estimated 10000 matches similar to: "Re-binning histogram data"

2008 Feb 11
2
Questions about histograms
Hello I'm doing some experiments with the various histogram functions and I have a two questions about the "prob" option and binning. First, here's a simple plot of my data using the default hist() function: > hist(data[,1], prob = TRUE, xlim = c(0, 35)) http://go.sneakymustard.com/tmp/hist.jpg My first question is regarding the resulting plot from hist.scott() and
2007 Apr 19
1
Histogram with uneven bins
Hi R-helpers I would like to produce a histogram with uneven bins (e.g., 0, 1-2, 3-5, 6-10, 10-20, >20) but I would like the resulting bars to be the same width ( i.e., a bar's width would not be proportional to its corresponding bin size). Also, the x and y axes of my histograms frequently (almost always, actually) extend beyond the axis labels (i.e., there are unlabeled bars). I would
2006 Apr 05
1
Bin by bin histogram comparisons
Hello, I have created two histograms with: hist2d(gps2, nbins=200, col = c("white",heat.colors(16))) Both of them have the same range and the same number of bins. Now I would like to compare them bin by bin and plot the results. Could someone please tell me how to do that. I searched the man pages and the web, but couldn't find anything. Thank you very much. Phil
2013 Jan 26
1
Attempting to confirm a program i wrote in C (normalize 2 datasets, transform into histogram, transform into CDF, perform KS test)
I have written a program in C that two xy datasets, aligns these 2 datasets based on shared features, transforms them into equal sized histograms, transforms the histograms into cumulative distribution functions (via GSL) and finally performs a KS_test. I am wanting to validate my program's results and figure'd i would use R but i am kinda stuck at ithe histograms (I have 2 histogram
2008 Feb 26
4
"Raw" histogram plots
Hello I need to plot a histogram, but insted of using bars, I'd like to plot the data points. I've been doing it like this so far: h <- hist(x, plot = F) plot(y = x$counts / sum(x$counts), x = x$breaks[2:length(x$breaks)], type = "p", log = "xy") Sometimes I want to have a look at the "raw" data (avoiding any kind of binning). When x
2012 Dec 06
2
Best way to coerce numerical data to a predetermined histogram bin?
Folks: Say I have a set of histogram breaks: breaks=c(1:10,15) # With bin ids: bin_ids=1:(length(breaks)-1) # and some data (note that some of it falls outside the breaks: data=runif(min=1,max=20,n=100) *** What is the MOST EFFICIENT way to "classify" data into the histogram bins (return the bin_ids) and, say, return NA if the value falls outside of the bins. By classify, I mean
2003 Jul 03
4
Generating a vector for breaks in a histogram
Hi I have two lots of numbers which I would like to histogram using the hist() function. For comparative reasons, I want them to be on the same scale, which I can use the xlim and ylim options to achieve. However, having them on the same scale is meaningless unless they have the same "breaks". Consulting the documentation, there are 4 ways of defining the number of breaks, only one
2011 May 05
4
Insert values to histogram
I'm trying to add the exact value on top of each column of an Histogram, i have been trying with the text function but it doesn't work. The problem is that the program it self decides the exact value to give to each column, and ther is not like in a bar-plot that I know exactly which values are been plotting. If anyone have any new idea on how to do this Thanks Matias -- View this
2002 Sep 06
3
Histogram Ranking
Hello, This is not exactly an R question, but I suspect that there is an R procedure that does what I am calling (for lack of a better name) "histogram ranking". I'm trying to evaluate a set of regression features by segregating by target class and comparing the feature histograms. My idea is that if the histograms are the same for two different classes then there is no
2003 Oct 28
1
stacking histograms
Hi, I have a set of observations which are divided into two sets A and B. I have some code that bins the dataset into 10 bins based on the max and min of the observed values. I would like to make a histogram of A & B using my calculated bins but plot the distribution of B on top of A (like a stacked barplot). This is possible since both sets A & B are binned using the same bin ranges.
2012 May 20
2
Histograms with bin proportions on the y-axis
I have what is probably a simple problem. I have a data file from an MCMC Bayes estimation problem that is a vector of 500,000 numeric values (just one variable) ranging from 100,000 to 700,000. I need to display the histogram of this data in a high quality graphic for a figure in a journal publication. I want 100 bins so as to display a reasonable complete and smooth histogram, and I need the
1999 Jun 08
3
histograms
> >>>>> "PD" == Peter Dalgaard BSA <p.dalgaard at biostat.ku.dk> writes: > > PD> "Venables, Bill (CMIS, Cleveland)" <Bill.Venables at cmis.CSIRO.AU> > PD> writes: > >> The fact that every elementary book on statistics does it this way > >> does not make it correct. To be helpful, a histogram really
2005 Mar 10
1
Transparent colors OR two series on one histogram
Hi, I want to be able to plot a single histogram of a measured trait with trait values from two conditions on the same histogram to allow easy comparison. I have previously done this in excel by plotting the two series on a single bargraph having calculated frequencies in bins. You then get one condition plotted immediately to the right of the other. I hope that makes sense? I don't
2013 Feb 08
2
Count of Histogram Bins using Shingles with lattice
I know that I can get a count of histogram bins in base R with plot=FALSE. However, I'd like to do the same thing with lattice. The problem is that I've set up shingles, and I'd like to get the count within each bin within each shingle. plot=FALSE doesn't seem to do it. [[alternative HTML version deleted]]
2011 Aug 10
2
Histograms in R
HI everyone, I'm plotting a histogram in R and within that histogram i need to demonstrate the percentage of another variable (Percentage of MutStatus) within the bins plotted inthe histogram....I don't know how to do that! Data:Validation_Status Mutation_Status TvarRatio Wildtype None 0.08 Wildtype None 0.08 Wildtype None 0.08 Wildtype None 0.08 Wildtype None 0.080139373 Wildtype None
2007 Mar 08
2
Using logarithmic y-axis (density) in a histogram
Hi, I am searching for a possibility to display a logarithimic y-axis in a histogram. With plot that's easy (e.g. plot(1:10, log="y") but for histograms this does not work the same way: I tried hist(rnorm(1000), freq=FALSE, seq(-4, 4, .5), ylim=c(0.001, 0.5), log="y") Which gives the expected histogram but also warnings for my log="y" command
2009 Nov 06
2
Binning of integers with hist() function odd results (PR#14046)
Full_Name: Gerald Guglielmo Version: 2.8.1 (2008-12-22) OS: OSX Leopard Submission from: (NULL) (131.225.103.35) When I attempt to use the hist() function to bin integers the behavior seems very odd as the bin boundary seems inconsistent across the various bins. For some bins the upper boundary includes the next integer value, while in others it does not. If I add 0.1 to every value, then the
2017 Aug 14
1
Lattice Histogram Scaling
I am trying to do some comparisons of density estimators using lattice. The code below attempts to plot the same histogram in each panel and then overplots a kernel estimate with different bandwidths. Finding packet.number() was a bit arduous, but seems to do what I want. My concern now is that close examination of the 4 histograms reveals that they are different even though they use the same
2008 Aug 19
1
Histogram binning
I am trying to produce frequencies in defined intervals however I can't seem to figure out how to get R to bin my data the way I want it to. I have several thousand lengths of fish that I want to be binned as follows: Ex. Length Bin 209 200 219 210 431 430 727 720 That is, bins with any length equal to or greater than the lower
2017 Aug 15
1
Lattice Histogram Scaling
My apologies, the data can now be found at: url <- "http://www.econ.uiuc.edu/~roger/research/ebayes/velo.d" x <- scan(url,skip = 1) If I could get each of the histograms to mimic what is produced by hist(x, 100, freq = FALSE) I?ve experimented with xlim, ylim, without success so far... url: www.econ.uiuc.edu/~roger Roger Koenker email rkoenker at uiuc.edu