int size = values.columns % outputInterval != 0 ? values.columns / outputInterval + 1 : values.columns; \r
double[] v = new double[size];\r
int sc = infoData[i*4+1];\r
- int c = sc > 0 ? sc-1 : 1-sc;\r
+ int c = sc > 0 ? sc-1 : -sc-1;\r
//System.out.println("i=" + i + ", sc=" + sc + ", c=" + c);\r
for(int j=0;j<v.length;++j) {\r
int adjusted = j * outputInterval;\r
int rows = header.rows;\r
double[] v = new double[size];\r
int sc = infoData[column * 4 + 1];\r
- int c = sc > 0 ? sc-1 : 1-sc;\r
+ int c = sc > 0 ? sc-1 : -sc-1;\r
\r
\r
\r
int rows = header.rows;\r
double[] v = new double[count];\r
int sc = infoData[row * 4 + 1];\r
- int c = sc > 0 ? sc-1 : 1-sc;\r
+ int c = sc > 0 ? sc-1 : -sc-1;\r
\r
\r
\r
\r
private double[][] readRows(MatrixHeader header, List<Integer> unSortedRows, InputStream in)throws IOException {\r
\r
- \r
- ;\r
- \r
if (header.type != 0)\r
throw new IOException("Only double type supported");\r
for (int row : unSortedRows)\r
int row = unSortedRows.get(i);\r
//vs[i] = new double[size];\r
usc[i] = infoData[row * 4 + 1];\r
- uc[i] = usc[i] > 0 ? usc[i]-1 : 1-usc[i];\r
+ uc[i] = usc[i] > 0 ? usc[i]-1 : -usc[i]-1;\r
}\r
\r
//Map<Integer, Integer> cToRow = new HashMap<Integer, Integer>();\r
int row = unSortedRows.get(i);\r
//vs[i] = new double[count];\r
usc[i] = infoData[row * 4 + 1];\r
- uc[i] = usc[i] > 0 ? usc[i]-1 : 1-usc[i];\r
+ uc[i] = usc[i] > 0 ? usc[i]-1 : -usc[i]-1;\r
}\r
\r
//Map<Integer, Integer> cToRow = new HashMap<Integer, Integer>();\r