All Questions
Tagged with statistics python-3.x
326
questions
0
votes
0
answers
47
views
How do we verify standard error implementation in a PyTorch-based logistic regression code?
I am currently implementing a logistic regression code using PyTorch and running it on a GPU. Below, I have provided a portion of the code. Following the model training, my objective is to obtain the ...
-1
votes
1
answer
89
views
Generating a PDF from Monte carlo Simulation [closed]
If I have an analytical pdf of a generated random variable like this
y= (x**(d-1)*e**(-x/g))/(math.gamma(d)*g**d)
where d and g are constants
How to generate this pdf using the Monte-Carlo simulation
...
0
votes
0
answers
139
views
Python Dunn Post Hoc Test same p-values
I'm learning statistics and while playing with post hoc tests, I noticed that Dunn's test returns the same p-value twice. I tried a different data set and the error repeated itself.
import pandas as ...
1
vote
1
answer
131
views
What is the most appropriate statistical test to check for significant differences in growth rates?
I have a commercial performance dataset such as the following:
Client Type
Channel
%growth_vol
Big Retail
A
9%
Big Retail
B
7%
Mid Retail
A
11%
Mid Retail
B
18%
Small Retail
A
21%
Small Retail
...
3
votes
2
answers
73
views
Python - Best Way to Get Mode With Scipy And Have Clean Code
import statistics
import scipy
# I would like to do this with scipy.
print(statistics.mode([1, 2, 3]))
# returns 1, I would like 'no mode'
print([statistics.mode([1, 1, 2, 3, 3]))
# returns 1, I ...
0
votes
1
answer
30
views
making columns out of items of columns of the dataframe
I think my problem lies in not correctly converting and then trying to loop through them,
I want to do a statistics analysis on each day activities, by making a negative list, then calculate if the ...
-1
votes
1
answer
378
views
How to find correlation between two datasets in ml
'How to find correlation between two different datasets in ml'?
how to find ow this datasets are correlated are not?
example below dataset which has different columns names also
df1
gene s1 s2 s3
1 ...
0
votes
1
answer
32
views
Python Pandas - level exceeded % of time
I'm looking for a quick way to calculate a statistical value exceeded % of the time in a 3D matrix. I was looking at using python and pandas but as a newbie I can get my data using xarray in but can't ...
1
vote
0
answers
319
views
Forecasting seasonality factor using statsmodels - X13 ARIMA
I possess a weekly set of data that I combined into monthly series for the purpose of utilizing statsmodels' X13 ARIMA. By employing the provided settings, I can obtain seasonally adjusted data. ...
0
votes
0
answers
81
views
Fast estimation of lagged covariance
I am working on a bigger function whose main bottleneck is the estimation of lagged covariance. I couldn't find any function, so I had to make my own:
def crosscov(signal1, signal2):
lags = numpy....
0
votes
1
answer
317
views
Add noise to multiple columns with different means and std in a pandas dataframe
I have a DataFrame of float type values containing about 80 000 rows and 100 different features, each one with a very different distribution than the other (different means and std). It is a ...
0
votes
0
answers
30
views
Why is that I am not getting normalized values, when I use 'density=True' parameter in matplotlib.pyplot.hist() [duplicate]
I have the following data and I am trying to fit a PDF using his data and matplotlib.pyplot.hist() function.
bs_slope_reps
array([0.0520316 , 0.05160929, 0.04848691, 0.04998295, 0.04404885,
0....
0
votes
1
answer
284
views
When is it appropriate to use Python's fmean instead of mean?
Python 3.8 released fmean as part of the statistics module, which supplements the existing mean function in the same module. As per the docs:
Convert data to floats and compute the arithmetic mean. ...
0
votes
2
answers
227
views
How to Demonstrate that 68%, 95%, and 99.7% of the values in s are indeed within 1, 2, and 3 standard distributions of the mean?
I have a pandas series s where the data follows a normal distribution.
I have 100 numbers in this series. I want to demonstrate that 68%, 95%, and 99.7% of the values in s are indeed within 1, 2, and ...
0
votes
0
answers
35
views
Find the values of variables at which minimize of the maximum of a function happens?
I am trying to write a python code to find the value of say x, y at which maximum of certain functions say f_1(x,y) and f_2(x,y) gets minimized.
Currently, I am doing the same in Mathematica but it is ...