33 items
P-value Significance Check Bug
Code QuizUnderstanding P-values and Correlation
QuizPopulation Variance Bug
Code QuizMean vs Median in Skewed Data
QuizHypothesis Testing, P-values & Causation
Slides / VideoP-values and Correlation vs Causation
FlashcardHypothesis Testing, p-values & Intervals
Slides / VideoP-values & Confidence Intervals
FlashcardExtracting an Eigenvector from np.linalg.eig
Code QuizData as Vectors and Matrices
Slides / VideoGradients and Partial Derivatives
Slides / VideoSingular Value Decomposition Basics
Slides / VideoMatrix Transpose and Inverse
Slides / VideoLinear Independence, Span, and Basis
Slides / VideoVector Norms and Distance Metrics
Slides / VideoDot Product and Vector Similarity
Slides / VideoMatrix Multiplication in AI
Slides / VideoMatrices and Matrix Operations
Slides / VideoVectors and Vector Operations
Slides / VideoConfidence Intervals
Slides / VideoHypothesis Testing and p-values
Slides / VideoSampling and the Central Limit Theorem
Slides / VideoDescriptive Statistics: Center and Spread
Slides / VideoMaximum Likelihood Estimation
Slides / VideoJoint, Marginal, Conditional Distributions
Slides / VideoCovariance and Correlation
Slides / VideoExpectation, Variance, Standard Deviation
Slides / VideoBayes' Theorem in AI
Slides / VideoConditional Probability and Independence
Slides / VideoGaussian, Bernoulli, Binomial Distributions
Slides / VideoDiscrete vs Continuous Distributions
Slides / VideoRandom Variables and Distributions
Slides / VideoEigenvalues and Eigenvectors Basics
Slides / VideoP-value Significance Check Bug
Spot the reversed comparison when deciding statistical significance from a p-value.
alpha = 0.05
p_value = 0.03
# We reject the null hypothesis when the result is significant
def is_significant(p_value, alpha):
return p_value > alpha
if is_significant(p_value, alpha):
print("Reject the null hypothesis (significant)")
else:
print("Fail to reject the null hypothesis")What is the bug in this significance-testing code?