I am trying to understand the intricacies of Linear Regression (1 predictor, 1 response). I am using Istanbul Stock Exchange dataset (https://www.kaggle.com/uciml/istanbul-stock-exchange) to do the same. I am using the column FTSE as my predictor variable and USD BASED ISE as my response variable.
I am writing my own Python (v 3.5.6) methods for all mathematical computation tasks viz. calculating $\beta$s ($\beta_{0}$ and $\beta_{1}$ in my case), calculating MSE, calculating $R^{2}$ etc. I have successfully calculated $\beta$s and could correctly estimate MSE, $R^{2}$ values.
I am trying to understand Boostrap and use the same to estimate
- Confidence intervals for coefficients $\beta_{0}$ and $\beta_{1}$
- Calculate t-statistic for $\beta_{0}$ and $\beta_{1}$
- Calculate p-value for $\beta_{0}$ and $\beta_{1}$
I am trying to calculate the above mentioned statistics without using any statistical package. I have written a function that takes my input dataset and generates 1,00,000 bootstrap samples out of it. For each of these samples I have obtained $\beta_{0}$ and $\beta_{1}$ values. In a nutshell, I have 1,00,000 $\beta_{0}$ and $\beta_{1}$ values. Using these list of values, how do I calculate statistics mentioned in (1), (2) and (3)