Displaying 1 result from an estimated 1 matches for "explanataion".
Did you mean:
explaination
2006 Jan 22
1
Solve for x in Ax=B with vectors, not matrices
Hello R-helpers,
What I have: I am working with vectors not matrice:
#Basic equations
A <-c(-20,-9,-2)
x <-c(0.17,0.22,0.61)
B <- crossprod(A,x)
# R matrix multiplication works with vectors
A%*%x==B # Is true...
Question: If x is unknown and A and B are known, how do I solve for x in R?
solve(A,B) won't work because A is not a square matrix
solve(A,B)
Error in solve.default(A,