Skip to main content

All Questions

Tagged with
0 votes
0 answers
35 views

How to create rv_histogram from known probability density function values

Let's say there is a distribution, and all what is known about the distribution is the value of its probability density function in a small range(e.g. from 0.0 to 0.001). Then, I want to use ...
Tonny Tc's user avatar
  • 920
1 vote
1 answer
41 views

P-Value not matching test statistic in Kolmogorov–Smirnov test (stats.kstest)

I am trying to learn how to use the Kolmogorov–Smirnov test in scipy (stats.kstest). For a simple problem like the example in the documentation, the test statistic for the one sample test seems to be ...
BigGulpshuh's user avatar
0 votes
1 answer
23 views

Z-Score as measurement of diverging values

I've been trying to use the z-score to filter out odd values in python. For the calculation I've used the version scipy is offering, vs calculating it myself using numpy and the mean and std functions....
mayen's user avatar
  • 122
2 votes
0 answers
45 views

How to implement a mixture of gamma distributions in Python without Bayes'?

I am trying to create examples to compare and contrast Bayesian MCMC (e.g. HMC) with non-Bayesian equivalents. One of the cases I am finding difficult is creating a mixture of gamma distributions. I ...
Galen's user avatar
  • 1,278
1 vote
2 answers
48 views

Subclassing scipy.stats.rv_continuous for truncated distribution

I would like to create a random variable from a truncated complementary error function. For this I want to subclass scipy.stats.rv_continuous. I have checked Subclassing scipy's continuous ...
Mister Mak's user avatar
0 votes
1 answer
62 views

TypeError: ufunc 'isnan' not supported for the input types - while performing Mann-Whitney U test

I have two data frames,primary_tumor_df and healthy_tissue_df to perform the Mann-Whitney U test. I have also removed nan values from both the data frames. Structure of primary_tumor_df. Structure of ...
Rabin Bishwokarma's user avatar
0 votes
0 answers
37 views

statsmodels qqplot doesn't match when using fit=True and scipy.stats.dist.fit

I was researching how quantile-quantile plots work and came across the following inconsistency: I was trying to compare quantiles from uniformerly distributed sample against normal distribution ...
makcymal's user avatar
0 votes
0 answers
30 views

Adding Boundaries to Scipy.Stats KDE Plots

I am plotting (x,y) data on a coordinate plane using a gaussian kde from the scipy stats library. While I want the kde plot to be able to extrapolate and assign a probability to areas within the map, ...
cjmess01's user avatar
0 votes
1 answer
73 views

Mismatching Python and MATLAB

I have starting to fit lognormal distribution to my data, but I was a bit sceptical about the results I got. So, I double checked it with MATLAB and found completely different results. The fitting ...
matt's user avatar
  • 29
0 votes
0 answers
117 views

problem with inputs for estimating earth mover distance with emd from python ot package

when implementing the emd and emd2 functions from the ot package here I'm a little confused on how to input a,b to be consistent with M, the cost matrix. without the a,b inputs, things work as I ...
yungmist's user avatar
1 vote
1 answer
46 views

Scipy Differential Evolution - Extraction of percentage of invalid population energies (via callback?)

I am currently working on an optimization problem and would like to extract the information of the fraction of invalid population energies from the package during each iteration step of the ...
Bb92's user avatar
  • 11
2 votes
1 answer
68 views

Computing multivariate normal integral over box region in SciPy

I am trying to evaluate the multivariate normal distribution to get the probability that 1 < z1 < 2.178 and 2.178 < z2 < inf. The mean of the distribution is zero, all variances are 1, and ...
clog14's user avatar
  • 1,641
0 votes
0 answers
90 views

How can I calculate percentile for every single data inside an xarray dataset

I have a dataset of one variable with the dimension of time, lat, Lon. The dataset looks like the following and it has several grids where there is NaN values: <xarray.Dataset> Dimensions: (...
nishanuw's user avatar
1 vote
0 answers
97 views

Best way to calculate percentile for every single value from actual and very large sized daily data (time 36500 X lon 3600 X lat 1500)

I have NETCDF files consisting of actual measurements of different variables at the daily scale and in a 3D format (time, lat, lon). The data size is huge, it is for 150 years at 0.1 degree spatial ...
nishanuw's user avatar
0 votes
2 answers
197 views

Combine rows and columns to create a 2x2 table for Fisher's exact test

I need to perform a test of independence on the following crosstab ct using python: Since there are some values less than 5, I cannot perform the chi-square test of independence. Instead, I need to ...
Oussema Chaabouni's user avatar

15 30 50 per page
1
2 3 4 5
59