Login
Login

Reply To: Failed to Compute inverse

Home 21090308 Forums Numerical Method Linear Algebra Failed to Compute inverse Reply To: Failed to Compute inverse

#5451
saeid
Member

Thanks again for your support.

Below is a java compilable code, along with an attached CSV file for the data input.

looking forward for your reply. and really appreciate your help.

double[][] RawData = new double [78][11];
//data input through Scanner
Scanner dataIn =null;
String getDataIn;
getDataIn = “PATH\\rawData.csv”; //add your path to the rawData.csv file

/*just in case; path should be like, c:\\user\\documents\\rawData.csv*/

try{
dataIn = new Scanner (new BufferedReader (new FileReader (getDataIn)));
for(int i = 0; i< 78; i ++) { for (int j= 0; j < 11 ; j ++) { RawData[i][j] = dataIn.nextDouble(); } } }catch(Exception e) {System.out.println(e);} //FACTOR ANALYSIS DenseMatrix Data; Data = new DenseMatrix(RawData); FactorAnalysis F = new FactorAnalysis(Data,5); F.S(); F.nFactors(); F.nVariables(); F.getEstimators(100);