» Home » Zipf » Page 1
Drawing the Zipf distribution
by lwl_seu in Programming Languages

I have a dataset with zipf law distribution, and now i want compare it with standard zipf diagram, this is my R code:


f <- read.table('/myfile.txt',sep=' ',header=T)
attach(f)
fs <- f[order(cnt), ]
detach(f)
n = 1:dim(fs)[1]
plot(fs[,2]~n)

Now i want to compare it with zipf in the same plot


Generate random numbers distributed by Zipf
by rgmarcha in Coding

The Zipf probability distribution is often used to model file size distribution or item access distributions on items in P2P systems. e.g. "Web Caching and Zip like Distribution Evidence and Implications", but neither Boost or the GSL (Gnu Scientific Library) provide an implementation to generate random numbers using this distribution. I have not found a (trustworthy) implementation using the c


curve fitting zipf distribution matplotlib python
by swilli89 in Programming Languages

I tried to fit the following plot(red dot) with zipf distribution in python, F~x^(-a)
I just simply chose a=0.56, and plot y = x^(-0.56) and I got the curve as follow:
which is obviously wrong, don't know how I can do the curve fit



Next
Privacy Policy - Copyrights Notice - Feedback - Report Violation - RSS 2014 © bighow.org All Rights Reserved .