def _pivot_col(T, tol=<NUM_LIT>, bland=False):
ma = np.ma.masked_where(T[-<NUM_LIT:1>, :-<NUM_LIT:1>] >= -tol, T[-<NUM_LIT:1>, :-<NUM_LIT:1>], copy=False)<EOL>if ma.count() == <NUM_LIT:0>:<EOL><INDENT>return False, np.nan<EOL><DEDENT>if bland:<EOL><INDENT>return True, np.where(ma.mask == False)[<NUM_LIT:0>][<NUM_LIT:0>]<EOL><DEDENT>return True, np.ma.where(ma == ma.min())[<NUM_LIT:0>][<NUM_LIT:0>]<EOL>
Given a linear programming simplex tableau, determine the column
of the variable to enter the basis.

Parameters
----------
T : 2D ndarray
    The simplex tableau.
tol : float
    Elements in the objective row larger than -tol will not be considered
    for pivoting.  Nominally this value is zero, but numerical issues
    cause a tolerance about zero to be necessary.
bland : bool
    If True, use Bland's rule for selection of the column (select the
    first column with a negative coefficient in the objective row,
    regardless of magnitude).

Returns
-------
status: bool
    True if a suitable pivot column was found, otherwise False.
    A return of False indicates that the linear programming simplex
    algorithm is complete.
col: int
    The index of the column of the pivot element.
    If status is False, col will be returned as nan.