For a Sample S, equal to {1 3 6 9 10 12 15 17 18 20} with Sample Size of n = 10:
Sample Mean xbar is given by [∑x]/n equal to [1+3+6+9+10+12+15+17+18+20]÷10 or 111/10 or 11.1.
Sample Variance is given by [∑(x−xbar)2]÷(n−1) or [(1−11.1)2+(3−11.1)2+(6−11.1)2+(9−11.1)2+(10−11.1)2+(12−11.1)2+(15−11.1)2+(17−11.1)2+(18−11.1)2+(20−11.1)2]÷(10−1), equal to 41.877777777777... (For Sample Variance, divide by (n-1); for Population Variance, divide by n.)
Sample Standard Deviation sx-bar is given by the Square Root Of The Sample Variance or √41.87777777777 equal to 6.471304179.
Margin Of Error Of A Confidence Interval is given by ±zsx-bar where z is the number of Standard Deviation Units from the Sample Mean. For a 95% Confidence Interval, the Margin Of Error is equal to ±1.96√41.87777777777 or ±12.68375619.