Python Program using numpy:-
---------------------------------------------------------------
import numpy
x=[1,2,4,6,12]
m=numpy.mean(x)
v=numpy.var(x)
print "Mean of the list is ",m
print "Variance of the list is ",v
--------------------------------------------------------------------
Program Output:-
----------------------------------------------------------
Finally mean is-------5
Variance is---------15.2
--------------------------------------------------
Explanation:-
------------------------------------------
1.we import numpy to calculate Mean and Variance in python
2.Mean is simply "Average of all numbers"--------------------(1+2+4+6+12)/5=5
3.Formula for variance is below
Steps:-
X1=1,
X2=2,
X3=4,
X4=6,
X5=12
------------------------
Mean(u)=5
-----------------
Number of items in the list(n)=5
----------------
Square of (1-5)=16
Square of (2-5)=9
Square of (4-5)=1
Square of (6-5)=1
Square of (12-5)=49
--------------------------------------------
Add all the elements=16+9+1+1+49=76
So finally variance=76/5=15.2
------------------------------------------------------------------------------
If you have any doubts regarding anything please comment defintly i will respond.Please please rate if you are satisfied.Thank you.
4. Find & such that |--^x=12,< for all \x + 2<8.
6. For the probability density function given by +1) -1<x<1, compute, using the definition the mean and variance of the distribution.
The following ψ are m.gf of some random variable X. Find EN] and Var(X) in each case. (a) ψ(t) = e2(e-1),-oo < t < oo.
C. (Theory) • Prove that if X Exp(x) for some > 0, ² = Var(x) = 1 / 2
6 Suppose that X and Y are random variables such that Var(X) Var(Y)-2 and Cov(x,y)- 1. Find the value of Var(3.X-Y+2)
6 Suppose that X and Y are random variables such that Var(X)-Var(Y)-2 and Cov(x,y)- 1. Find the value of Var(3.X-Y + 2)
6. Suppose that X and Y are random variables such that Var(X)=Var(y)-2 and Cov(x,y)-1. the value of Var(ax-y-2). Find
Obtain E(Z|X), Var(Z|X) and verify that E(E(Z|X)) =E(Z), Var(E(Z|X))+E(Var(Z|X)) =Var(Z) 3. Let X, Y be independent Exponential (1) random variables. Define 1, if X Y<2 Obtain E (Z|X), Var(ZX) and verify that E(E(Zx)) E(Z), Var(E(Z|X))+E(Var(Z|X)) - Var(Z)
1. The random variable X is Gaussian with mean 3 and variance 4; that is X ~ N(3,4). $x() = veze sve [5] (a) Find P(-1 < X < 5), the probability that X is between -1 and 5 (inclusive). Write your answer in terms of the 0 () function. [5] (b) Find P(X2 – 3 < 6). Write your answer in terms of the 0 () function. [5] (c) We know from class that the random variable Y =...
. (8pts) X1, X,X x. . X, is a random sample with a common probability density function, (), f(x) 6Ax3c"/?, x > 0 and ? > 0. 604 Note that E(X-4? and Var(X-4g2. a) (4pts) Find a maximum likelihood estimator of ?, say ?MLE. (b) (4pts) Find the mean squared error of ?MLE-