Révision 1754

tmp/org.txm.ca.core/src/org/txm/ca/core/chartsengine/r/REigenvaluesChartCreator.java (revision 1754)
55 55
		REXP sv;
56 56
		try {
57 57
			sv = RWorkspace.getRWorkspaceInstance().eval("length("+ca.getSymbol()+"$eig$eigenvalue)");  //$NON-NLS-1$ $NON-NLS-2$
58

  
59 58
			int ncol = sv.asInteger();
60 59

  
61
			for(int i = 0, c = ncol; i < c; i++) {
60
			for (int i = 0, c = ncol; i < c; i++) {
62 61
				if(i > 0)	 {
63 62
					xLabels.append(", "); //$NON-NLS-1$
64 63
				}
......
66 65
			}
67 66
			xLabels.append(")"); //$NON-NLS-1$
68 67

  
69
			String cmd = "tmpY <- " + ca.getSymbol() + "$eig$eigenvalue[1:length(" + ca.getSymbol() + "$eig$eigenvalue) - 1];\n"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
68
			String cmd = "tmpY <- " + ca.getSymbol() + "$eig$eigenvalue[1:" + ncol + "];\n"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
70 69
			cmd += "barplot(tmpY, main=\"" //$NON-NLS-1$
71 70
					+ CACoreMessages.eigenvalues + "\", ylab=\"" + //$NON-NLS-1$
72 71
					CACoreMessages.eigenvalue + "\", xlab=\"" + //$NON-NLS-1$

Formats disponibles : Unified diff