simulariumio/trajectory_converter.py
def write_external_JSON(external_data: TrajectoryData, output_path: str):
        """
        Save the given data in .simularium JSON format
        at the output path

        Parameters
        ----------
        external_data: TrajectoryData
            the data to save
        output_path: str
            where to save the file
        """
        print("Writing JSON (external)-------------")
        buffer_data = TrajectoryConverter._read_trajectory_data(external_data)
        with open(f"{output_path}.simularium", "w+") as outfile:
            json.dump(buffer_data, outfile)
        print(f"saved to {output_path}.simularium")

        Save the given data in .simularium JSON format
        at the output path

        Parameters
        ----------
        external_data: TrajectoryData
            the data to save
        output_path: str
            where to save the file
        
Save the given data in .simularium JSON format
at the output path

Parameters

TrajectoryData
the data to save
output_path: str
where to save the file
Save the given data in . simularium JSON format at the output path Parameters TrajectoryData the data to save output_path : str where to save the file
def write_external_JSON(external_data: TrajectoryData, output_path: str):
        print("Writing JSON (external)-------------")
        buffer_data = TrajectoryConverter._read_trajectory_data(external_data)
        with open(f"{output_path}.simularium", "w+") as outfile:
            json.dump(buffer_data, outfile)
        print(f"saved to {output_path}.simularium")
def write_external_JSON ( external_data : TrajectoryData , output_path : str ) : print ( "Writing JSON (external)-------------" ) buffer_data = TrajectoryConverter . _read_trajectory_data ( external_data ) with open ( f"{output_path}.simularium" , "w+" ) as outfile : json . dump ( buffer_data , outfile ) print ( f"saved to {output_path}.simularium" )
Save the given data in .simularium JSON format
at the output path
Save the given data in . simularium JSON format at the output path
"""
        Save the given data in .simularium JSON format
        at the output path

        Parameters
        ----------
        external_data: TrajectoryData
            the data to save
        output_path: str
            where to save the file
        """
external_data
TrajectoryData
output_path
str