code: def set_column(self, X, column, value):
          
  
          if isinstance(X, pd.DataFrame):
              X.loc[:, column] = value
  
          else:
              X[:, column] = value
  
          return X
docs: Sets a column on the matrix X with the given value.
  
          Args:
              X: `numpy.ndarray` or `pandas.DataFrame`.
              column: `int` or `str`.
              value: `np.ndarray` with shape (1,)
  
          Returns:
              `np.ndarray` or `pandas.DataFrame` with the inserted column.