lsq                 package:SparseM                 R Documentation

_L_e_a_s_t _S_q_u_a_r_e_s _P_r_o_b_l_e_m_s _i_n _S_u_r_v_e_y_i_n_g

_D_e_s_c_r_i_p_t_i_o_n:

     One of the four matrices from the least-squares solution of 
     problems in surveying that were used by Michael Saunders and Chris
     Paige  in the testing of LSQR

_U_s_a_g_e:

     data(lsq)

_F_o_r_m_a_t:

     A list of class 'matrix.csc.hb' or 'matrix.ssc.hb' depending on
     how the coefficient matrix is stored with the following
     components:

   _r_a  ra component of the csc or ssc format of the coefficient matrix,
        X. .tide ja   ja component of the csc or ssc format of the
        coefficient matrix, X. .tide ia   ia component of the csc or
        ssc format of the coefficient matrix, X. .tide rhs.ra   ra
        component of the right-hand-side, y, if stored in csc or ssc
        format; right-hand-side stored in dense vector or matrix
        otherwise.

   _r_h_s._j_a  ja component of the right-hand-side, y, if stored in csc or 
        ssc format; a null vector otherwise.

   _r_h_s._i_a  ia component of the right-hand-side, y, if stored in csc or
        ssc format; a null vector otherwise.

   _x_e_x_a_c_t vector of the exact solutions, b, if they exist; a null
        vector o therwise.   .tide guess  vector of the initial guess
        of the solutions if they exist; a null vector otherwise.

   _d_i_m dimenson of the coefficient matrix, X.

   _r_h_s._d_i_m dimenson of the right-hand-side, y.

   _r_h_s._m_o_d_e storage mode of the right-hand-side; can be full storage or
        same format as the coefficient matrix.

_R_e_f_e_r_e_n_c_e_s:

     Koenker, R and Ng, P. (2002).  SparseM:  A Sparse Matrix Package
     for R,
      <URL: http://www.econ.uiuc.edu/~roger/research>

     Matrix Market, <URL:
     http://math.nist.gov/MatrixMarket/data/Harwell-Boeing/lsq/lsq.html
     >

_S_e_e _A_l_s_o:

     'read.matrix.hb', 'write.matrix.hb'

_E_x_a_m_p_l_e_s:

     data(lsq)
     class(lsq) # -> [1] "matrix.csc.hb"
     model.matrix(lsq)->X
     class(X) # -> "matrix.csr"
     dim(X) # -> [1] 1850  712
     y <- model.response(lsq) # extract the rhs
     length(y) # [1] 1850 

