function convertCoords(wellPos) {
    var conversionMap = {A:1, B:2, C:3, D:4, E:5, F:6, G:7, H:8};
    // readNumeral function is used here to work both when wellPos
    // has format 'A5' as well as 'A05'
    try {
        var row = readNumeral(conversionMap[wellPos.charAt(0)]);
        var column = readNumeral(wellPos.slice(1));
    } catch(e) {
        // UnexpectedValueException
        throw "InvalidCoordinatesException:" + e;
    }
    if(column < 1 || column > 12) {
        throw "InvalidCoordinatesException";
    }
    return [row, column];
}
/*
 Converts a set of plate coordinates to a row and column number,
 e.g. 'C4' returns [3, 4]
*/
Converts a set of plate coordinates to a row and column number,
e.g.
Converts a set of plate coordinates to a row and column number e . g .
function convertCoords(wellPos) {
    var conversionMap = {A:1, B:2, C:3, D:4, E:5, F:6, G:7, H:8};
    try {
        var row = readNumeral(conversionMap[wellPos.charAt(0)]);
        var column = readNumeral(wellPos.slice(1));
    } catch(e) {
        throw "InvalidCoordinatesException:" + e;
    }
    if(column < 1 || column > 12) {
        throw "InvalidCoordinatesException";
    }
    return [row, column];
}
function convertCoords ( wellPos ) { var conversionMap = { A : 1 , B : 2 , C : 3 , D : 4 , E : 5 , F : 6 , G : 7 , H : 8 } ; try { var row = readNumeral ( conversionMap [ wellPos . charAt ( 0 ) ] ) ; var column = readNumeral ( wellPos . slice ( 1 ) ) ; } catch ( e ) { throw "InvalidCoordinatesException:" + e ; } if ( column < 1 || column > 12 ) { throw "InvalidCoordinatesException" ; } return [ row , column ] ; }
Converts a set of plate coordinates to a row and column number,
e.g.
Converts a set of plate coordinates to a row and column number e . g .
// readNumeral function is used here to work both when wellPos // has format 'A5' as well as 'A05' // UnexpectedValueException