similar to: How is the relation between Frequency and Counts in hist/density defined?

Displaying 20 results from an estimated 9000 matches similar to: "How is the relation between Frequency and Counts in hist/density defined?"

2008 Sep 01
1
warning with hist
Hello everybody, I don't understand the warning I get when executing the following code: x <- rnorm(100) h <- hist(x, plot= FALSE, freq = FALSE) If I don't use the plot-argument, I don't get a warning... Any explanations for me? Antje
2009 Apr 06
1
R and .net/C#
Hi There, There seems to be a way for calling R from .net. However, is there anyway for calling .net/C# code from R? Something similar to the RJava package for .net? Thanks a mil! Fayssal -- View this message in context: http://www.nabble.com/R-and-.net-C--tp22904715p22904715.html Sent from the R help mailing list archive at Nabble.com.
2009 Aug 25
2
table, sum, cat function
Hi, the second step in my exercice is to calculate the sum of the amout for each class et not the frequency i have this vector x           y 1          100 2          1500 3          3250 4          6250 5          2000 6           450 i want to use the function table and cat to calculate the sum of the amount in each class [0-1000], [1000-3000],[> 3000] Thank you for your help??
2010 Mar 16
1
C# DLL Library
Good afternoon everybody, I am sorry, this question might look trivial to some of you, but I read quite a lot of stuff about package creation and I would like a bit of you advices. I would like to develop a core library which I will be using both from R and from C#. I read that it was possible to import DLL to R. The thing is, I am not sure that the DLL created with C# will be compatible. I
2008 Aug 26
2
String search: Return "closest" match
Hi, I have to match names where names can be recorded with errors or additions. Now I am searching for a string search function which returns always the "closest" match. E.g. searching for "Washington" it should return only Washington but not Washington, D.C. But it also could be that the list contains only "Hamburg" but the record I am searching for is
2010 May 24
2
excluding on element from a list
Dear List, I am making a list of all the files in a folder and I want to exclude one file called "proj.current". This is the 31st file in a folder. Currently I use the command: tdirs <- list.files(pattern="proj.")[-31] However I would like to exclude it based on its name and not the position. Any advice would be useful. Thanks, Daisy Daisy Englert Duursma Room
2009 Aug 04
3
matrix
Hi I have dataset that consists of two columns AB 0.102 AC -0.002 BA -0.102 BC 0.270 CA 0.002 CB -0.270 I wish to create a matrix so that I can eventually plot the data. A B C A 1 0.102 -0.002 B -0.102 1 0.27 C 0.002 -0.27 1 Any help or guidance would be greatly
2010 Mar 13
2
Is this a bug (or a feature) in hist(x)$density ??
Hi all, A friend send me a question on why does this: x<-rpois(100,1) sum( hist(x)$density ) Gives out "2" I tried this: sum( hist(x, freq =T)$density ) It didn't help. Then he came back with the following insight: # with breaks b<-c(0,0.9,1:8) sum(hist(x,breaks=b)$density) # Much more then 2 # but if we add weights according to the interval length
2010 Mar 30
1
hist.default()$density
Dear developers, the current implementation of hist.default() calculates 'density' (and 'intensities') as dens <- counts/(n*h) where h has been calculated before as h <- diff(fuzzybreaks) which results in 'fuzzy' values for the density, see e.g. > tmp <- hist(1:10,breaks=c(-2.5,2.5,7.5,12.5),plot=FALSE) > print(tmp$density,digits=15) [1]
2009 Aug 19
1
Fw: Hist & kernel density estimates
For the hist estimate >par(mex=1.3) >dens<-density(q) >options(scipen=4) > ylim<-range(dens$y) > h<-hist(q,breaks="scott",freq=FALSE,probability=TRUE, +? right=FALSE,xlim=c(9000,16000),ylim=ylim,main="Histogram of q(scott)") > lines(dens) >box() ? For the kernel estimate>options(scipen=4) > d <- density(q, bw =
2013 Jan 22
3
density of hist(freq = FALSE) inversely affected by data magnitude
Hi, I have a couple of observations, a question or two, and perhaps a suggestion related to the plotting of density on the y-axis within the hist() function when freq=FALSE. I was using the function and trying to develop an intuitive understanding of what the density is telling me. After reading through this fairly helpful post:
2001 Oct 13
1
hist with relative frequency
Dear R People: Here is yet another histogram question (yahq), please: When I use the hist() command with freq=F, I get density on the side. I would really like to have relative frequency; that is, Rf = density/(sum(density)) Is there a step that I'm leaving out, please? thanks! Sincerely, Erin hodgess at uhddx01.dt.uh.edu
2012 Dec 02
0
superimpose density line over hist
>>>>> "Romain" == Romain Francois <[hidden email]> >>>>> on Tue, 13 Dec 2005 15:40:59 +0100 writes: ........ Romain> A few comments : Romain> - your code should be reproductible, otherwise it is useless. (that Romain> recommandation is on the posting guide) Romain> - that question is a top ten question
2012 Mar 14
2
sum(hist$density) == 2 ?!
> x <- rnorm(1000) > h <- hist(x,plot=FALSE) > sum(h$density) [1] 2 ----------------------------- shouldn't it be 1?! > h <- hist(x,plot=FALSE, breaks=(-4:4)) > sum(h$density) [1] 1 ----------------------------- now it's 1. why?! -- Sam Steingold (http://sds.podval.org/) on Ubuntu 11.10 (oneiric) X 11.0.11004000 http://www.childpsy.net/ http://www.memritv.org
2009 Jun 04
1
hist returning density larger than 1
The following code is giving me problems. I want to export densities of a distribution to a csv file. At the bottom of the code I use the hist function to generate the densities. But hist is returning values greater than 1. I don't understand, why. Any help you can supply is greatly appreciated. # Set word path dir<-"~/Research/MR Distribution Analysis/" setwd(dir)
2003 Jun 17
1
hist density...
Hi! Do not understand following behavior. > summary(test$dif) Min. 1st Qu. Median Mean 3rd Qu. Max. 0.7389 0.9713 0.9850 0.9818 1.0000 1.0000 length(test$dif) [1] 85879 tmp <- hist(test$dif,breaks=100,freq=FALSE) The density on the Y axis in the plot are in the range 0-200. Thought that the density should be in the range 0-1 (something like
2006 May 18
0
?hist and $density explanation
Hi, people. Within ?hist (using R 2.3.0), one reads: density: values f^(x[i]), as estimated density values. If 'all(diff(breaks) == 1)', they are the relative frequencies 'counts/n' and in general satisfy sum[i; f^(x[i]) (b[i+1]-b[i])] = 1, where b[i] = 'breaks[i]'. I trip on this explanation each time I read it. Some R guardians will be
1997 Dec 02
2
R-beta: wish: hist() returning breaks and counts
Hi, would it be possible to change the hist() function in future R Versions to accept a "plot=F" parameter (like hist() in S it should return a list with "breaks" and "counts" in this case). This change should be very simple. Albrecht ------------------------------------------------------------------------------- Albrecht Gebhardt email :
1997 Dec 02
2
R-beta: wish: hist() returning breaks and counts
Hi, would it be possible to change the hist() function in future R Versions to accept a "plot=F" parameter (like hist() in S it should return a list with "breaks" and "counts" in this case). This change should be very simple. Albrecht ------------------------------------------------------------------------------- Albrecht Gebhardt email :
2009 Jul 26
2
problems hist() and density
Hello, I have a problem with the hist() function and showing densities. The densities sum to 50 and not to 1! I use R version 2.9.1 (2009-06-26) and I load the seqinR library. My data is the following vector: [1] 0.1400000 0.2000000 0.2200000 0.2828283 0.1600000 0.1600000 0.3600000 [8] 0.1600000 0.2200000 0.2600000 0.2000000 0.3000000 0.2200000 0.2342342 [15] 0.1800000 0.2200000 0.1600000