Question

In: Statistics and Probability

Use R code Create a vector V with 8 elements (7,2,1,0,3,-1,-3,4): Transform that vector into a...

Use R code

Create a vector V with 8 elements (7,2,1,0,3,-1,-3,4):

  1. Transform that vector into a rectangular matrix A of dimensions 4X2 (4- rows, 2-columns);
  2. Create a matrix transpose to the above matrix A. Call that matrix AT;
  3. Calculate matrix products: A*AT and AT*A. Present the results. What are the dimensions of those two product matrices;
  4. Square matrixes sometimes have an inverse matrix. Try calculating inverse matrices (or matrixes, if you prefer) of above matrices (matrixes) A*AT and AT*A;
  5. Extend the above vector V with the ninth number of value -2. Do it elegantly by concatenating two vectors!;
  6. Transform that extended vector into a 3X3 matrix B.
  7. Calculate the inverse matrix of matrix B. Call it Binv. Demonstrate that the product of B and Binv is the same as the product of Binv and B and is equal to what?
  8. Determine the eigenvectors of matrixes B;
  9. Construct a new matrix C which is made by using each eigenvector of matrix B as a column. Calculate the product of matrix C and matrix B and the product of matrix B and C. Is there any significance to the elements of the product matrixes;
  10. Transform matrix B into a matrix with names columns and named rows;
  11. Transformed that fully “named” matrix into a data.frame;
  12. Ask the object you just created what is its class().

Solutions

Expert Solution


Related Solutions

Use R code to do the following!!!! 1. Create a vector v1 that will contain integers...
Use R code to do the following!!!! 1. Create a vector v1 that will contain integers from -30 to 60. 2. Copy v1 into a vector v2 and add names 'odd' or 'even' based on the value. 3. Copy v1 into a vector v3 and if the number can be divided by 3, replace it by 'NA'. 4. Assign the mean of v3 to v4 ignoring the 'NA'.
R-Studio (R Programming Language) 1. How would you create a vector `V` containing the values 0,...
R-Studio (R Programming Language) 1. How would you create a vector `V` containing the values 0, 0.25, 0.5, 0.75, and 1?    ```{r} #insert your code ``` 2. Name the elements of `V`: first, second, middle, fourth, last. Describe two ways of naming elements in `V` ```{r} #insert your code ``` 3. Suppose you keep track of your mileage each time you fill up. At your last 6 fill-ups the mileage was 65311 65624 65908 66219 66499 66821 67145 67447....
1. Let V and W be vector spaces over R. a) Show that if T: V...
1. Let V and W be vector spaces over R. a) Show that if T: V → W and S : V → W are both linear transformations, then the map S + T : V → W given by (S + T)(v) = S(v) + T(v) is also a linear transformation. b) Show that if R: V → W is a linear transformation and λ ∈ R, then the map λR: V → W is given by (λR)(v) =...
Find the 95% confidence interval of the mean of a vector in r code. The vector...
Find the 95% confidence interval of the mean of a vector in r code. The vector length is 100.
Let V be the vector space of all functions f : R → R. Consider the...
Let V be the vector space of all functions f : R → R. Consider the subspace W spanned by {sin(x), cos(x), e^x , e^−x}. The function T : W → W given by taking the derivative is a linear transformation a) B = {sin(x), cos(x), e^x , e^−x} is a basis for W. Find the matrix for T relative to B. b)Find all the eigenvalues of the matrix you found in the previous part and describe their eigenvectors. (One...
R Programming: create a vector for 1 to 31 and count the number of even and...
R Programming: create a vector for 1 to 31 and count the number of even and odds using ifelse()
(10pt) Let V and W be a vector space over R. Show that V × W...
(10pt) Let V and W be a vector space over R. Show that V × W together with (v0,w0)+(v1,w1)=(v0 +v1,w0 +w1) for v0,v1 ∈V, w0,w1 ∈W and λ·(v,w)=(λ·v,λ·w) for λ∈R, v∈V, w∈W is a vector space over R. (5pt)LetV beavectorspaceoverR,λ,μ∈R,andu,v∈V. Provethat (λ+μ)(u+v) = ((λu+λv)+μu)+μv. (In your proof, carefully refer which axioms of a vector space you use for every equality. Use brackets and refer to Axiom 2 if and when you change them.)
Create a PDA accepting the following languages: (a) {v$w$v R | w, v ∈ {0, 1}...
Create a PDA accepting the following languages: (a) {v$w$v R | w, v ∈ {0, 1} ∗} (b) {w | in w, the number of 0’s is the same as the number of 1’s}.
Code in C++ Objectives Use STL vector to create a wrapper class. Create Class: Planet Planet...
Code in C++ Objectives Use STL vector to create a wrapper class. Create Class: Planet Planet will be a simple class consisting of three fields: name: string representing the name of a planet, such as “Mars” madeOf: string representing the main element of the planet alienPopulation: int representing if the number of aliens living on the planet Your Planet class should have the following methods: Planet(name, madeOf, alienPopulation) // Constructor getName(): string // Returns a planet’s name getMadeOf(): String //...
Create a code for A vector for forecasting and the value of alpha and provides an...
Create a code for A vector for forecasting and the value of alpha and provides an exponential smoothing forecast for the given dataset within R.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT