## anonymous one year ago Need some help to start derive the general formula for leverage in a simple regression model using a single binary covariate? Consider a data set where the variable X takes only 0 or 1 values (e.g., Yes/No type, we code Yes = 1 and No = 0)

I know leverage is $h _{ii} =\frac{ 1 }{ n }+\frac{ (X_i-X^-)^{2} }{ \sum_{k=1}^{n}(X_k-X^-)^2 }$ $X^-$ is mean of X