packages/vaex-core/vaex/dataframe.py
def shallow_copy(self, virtual=True, variables=True):
        """Creates a (shallow) copy of the DataFrame.

        It will link to the same data, but will have its own state, e.g. virtual columns, variables, selection etc.

        """
        df = DataFrameLocal(self.name, self.path, self.column_names)
        df.columns.update(self.columns)
        df._length_unfiltered = self._length_unfiltered
        df._length_original = self._length_original
        df._index_end = self._index_end
        df._index_start = self._index_start
        df._active_fraction = self._active_fraction
        if virtual:
            df.virtual_columns.update(self.virtual_columns)
        if variables:
            df.variables.update(self.variables)
        # half shallow/deep copy
        # for key, value in self.selection_histories.items():
        # df.selection_histories[key] = list(value)
        # for key, value in self.selection_history_indices.items():
        # df.selection_history_indices[key] = value
        return df
def shallow_copy(self, virtual=True, variables=True):
        """Creates a (shallow) copy of the DataFrame.

        It will link to the same data, but will have its own state, e.g. virtual columns, variables, selection etc.

        """
        df = DataFrameLocal(self.name, self.path, self.column_names)
        df.columns.update(self.columns)
        df._length_unfiltered = self._length_unfiltered
        df._length_original = self._length_original
        df._index_end = self._index_end
        df._index_start = self._index_start
        df._active_fraction = self._active_fraction
        if virtual:
            df.virtual_columns.update(self.virtual_columns)
        if variables:
            df.variables.update(self.variables)
        # half shallow/deep copy
        # for key, value in self.selection_histories.items():
        # df.selection_histories[key] = list(value)
        # for key, value in self.selection_history_indices.items():
        # df.selection_history_indices[key] = value
        return df
def shallow_copy ( self , virtual = True , variables = True ) : df = DataFrameLocal ( self . name , self . path , self . column_names ) df . columns . update ( self . columns ) df . _length_unfiltered = self . _length_unfiltered df . _length_original = self . _length_original df . _index_end = self . _index_end df . _index_start = self . _index_start df . _active_fraction = self . _active_fraction if virtual : df . virtual_columns . update ( self . virtual_columns ) if variables : df . variables . update ( self . variables ) # half shallow/deep copy # for key, value in self.selection_histories.items(): # df.selection_histories[key] = list(value) # for key, value in self.selection_history_indices.items(): # df.selection_history_indices[key] = value return df
Creates a (shallow) copy of the DataFrame.

        It will link to the same data, but will have its own state, e.g. virtual columns, variables, selection etc.
Creates a ( shallow ) copy of the DataFrame .