annotate table_pandas_arithmetics.py @ 0:b722dba91064 draft default tip

planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
author recetox
date Wed, 29 Jan 2025 15:35:51 +0000
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
1 import argparse
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
2 import logging
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
3 from typing import List, Tuple
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
4
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
5
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
6 import numpy as np
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
7 import pandas as pd
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
8 from utils import LoadDataAction, SplitColumnIndicesAction, StoreOutputAction
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
9
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
10
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
11 # Constants for operations
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
12 OPERATIONS = {
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
13 "mul": np.multiply,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
14 "sub": np.subtract,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
15 "div": np.divide,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
16 "add": np.add,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
17 "pow": np.power,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
18 }
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
19
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
20
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
21 def perform_operation(df: pd.DataFrame, column_indices: List[int], operation: str, operand: float):
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
22 """
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
23 Perform the specified arithmetic operation on the given columns of the dataframe.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
24
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
25 Parameters:
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
26 df (pd.DataFrame): The input dataframe.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
27 column_indices (list): The 0-based indices of the columns to perform the operation on.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
28 operation (str): The arithmetic operation to perform.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
29 operand (float): The operand for the arithmetic operation.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
30
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
31 Returns:
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
32 pd.DataFrame: The dataframe with the operation applied.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
33 """
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
34 for column_index in column_indices:
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
35 column_name = df.columns[column_index]
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
36 df[column_name] = OPERATIONS[operation](df[column_name], operand)
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
37 return df
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
38
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
39
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
40 def main(input_dataset: pd.DataFrame, column_indices: List[int], operation: str, operand: float, output_dataset: Tuple[callable, str]):
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
41 """
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
42 Main function to load the dataset, perform the operation, and save the result.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
43
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
44 Parameters:
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
45 input_dataset (tuple): The input dataset and its file extension.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
46 column_indices (list): The 0-based indices of the columns to perform the operation on.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
47 operation (str): The arithmetic operation to perform.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
48 operand (float): The operand for the arithmetic operation.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
49 output_dataset (tuple): The output dataset and its file extension.
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
50 """
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
51 try:
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
52 df = perform_operation(input_dataset, column_indices, operation, operand)
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
53 write_func, file_path = output_dataset
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
54 write_func(df, file_path)
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
55 except Exception as e:
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
56 logging.error(f"Error in main function: {e}")
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
57 raise
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
58
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
59
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
60 if __name__ == "__main__":
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
61 logging.basicConfig(level=logging.INFO)
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
62 parser = argparse.ArgumentParser(
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
63 description="Perform arithmetic operations on dataframe columns."
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
64 )
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
65 parser.add_argument(
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
66 "--input_dataset",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
67 nargs=2,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
68 action=LoadDataAction,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
69 required=True,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
70 help="Path to the input dataset and its file extension (csv, tsv, parquet)",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
71 )
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
72 parser.add_argument(
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
73 "--columns",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
74 action=SplitColumnIndicesAction,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
75 required=True,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
76 help="Comma-separated list of 1-based indices of the columns to perform the operation on",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
77 )
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
78 parser.add_argument(
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
79 "--operation",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
80 type=str,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
81 choices=OPERATIONS.keys(),
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
82 required=True,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
83 help="Arithmetic operation to perform",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
84 )
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
85 parser.add_argument(
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
86 "--operand",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
87 type=float,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
88 required=True,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
89 help="Operand for the arithmetic operation",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
90 )
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
91 parser.add_argument(
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
92 "--output_dataset",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
93 nargs=2,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
94 action=StoreOutputAction,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
95 required=True,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
96 help="Path to the output dataset and its file extension (csv, tsv, parquet)",
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
97 )
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
98
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
99 args = parser.parse_args()
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
100 main(
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
101 args.input_dataset,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
102 args.columns,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
103 args.operation,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
104 args.operand,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
105 args.output_dataset,
b722dba91064 planemo upload for repository https://github.com/RECETOX/galaxytools/tree/master/tools/tables commit d0ff40eb2b536fec6c973c3a9ea8e7f31cd9a0d6
recetox
parents:
diff changeset
106 )