def _get_column(self, column_or_label):
c = column_or_label<EOL>if isinstance(c, collections.Hashable) and c in self.labels:<EOL><INDENT>return self[c]<EOL><DEDENT>elif isinstance(c, numbers.Integral):<EOL><INDENT>return self[c]<EOL><DEDENT>elif isinstance(c, str):<EOL><INDENT>raise ValueError('<STR_LIT>'.format(c, self.labels))<EOL><DEDENT>else:<EOL><INDENT>assert len(c) == self.num_rows, '<STR_LIT>'<EOL>return c<EOL><DEDENT>
Convert label to column and check column length.