public Object[] getBestLineCount() {
        Object[] ret = {"", 0};
        int count = jTable.getColumnCount();
        int finalCount = 0;
        
        int diagonalCount = getCount("diagonal", 0);
        int inverseCount = getCount("inverse", 0);
        
        if(diagonalCount > finalCount) {
            finalCount = diagonalCount;
            ret[0] = "diagonal";
        }
        if(inverseCount > finalCount) {
            finalCount = inverseCount;
            ret[0] = "inverse";
        }
        
        for(int i=0; i<count; i++) {
            int rowCount = getCount("row", i);
            int columnCount = getCount("column", i);
            
            if(rowCount > finalCount) {
                finalCount = rowCount;
                ret[0] = "row";
                ret[1] = i;
            }
            if(columnCount > finalCount) {
                finalCount = columnCount;
                ret[0] = "column";
                ret[1] = i;
            }
        }
        
        return ret;
    }