# Example 1: Continuous response (can be negative)
set.seed(123)
y1 <- rnorm(100)
detect_glm_family(y1)
# Example 2: Count data
y2 <- rpois(100, lambda = 5)
detect_glm_family(y2)
# Example 3: Proportion data
y3 <- rbeta(100, 2, 5)
detect_glm_family(y3)
Run the code above in your browser using DataLab