Mercurial > repos > bimib > cobraxy
comparison COBRAxy/docs/tools/ras-generator.md @ 542:fcdbc81feb45 draft
Uploaded
| author | francesco_lapi |
|---|---|
| date | Sun, 26 Oct 2025 19:27:41 +0000 |
| parents | fd53d42348bd |
| children | 73f2f7e2be17 |
comparison
equal
deleted
inserted
replaced
| 541:fa93040a75af | 542:fcdbc81feb45 |
|---|---|
| 16 | 16 |
| 17 ### Required Parameters | 17 ### Required Parameters |
| 18 | 18 |
| 19 | Parameter | Short | Type | Description | | 19 | Parameter | Short | Type | Description | |
| 20 |-----------|--------|------|-------------| | 20 |-----------|--------|------|-------------| |
| 21 | `--tool_dir` | `-td` | string | COBRAxy installation directory | | |
| 22 | `--input` | `-in` | file | Gene expression dataset (TSV format) | | 21 | `--input` | `-in` | file | Gene expression dataset (TSV format) | |
| 23 | `--ras_output` | `-ra` | file | Output file for RAS values | | 22 | `--ras_output` | `-ra` | file | Output file for RAS values | |
| 24 | `--rules_selector` | `-rs` | choice | Built-in model (ENGRO2, Recon, HMRcore) | | 23 | `--rules_selector` | `-rs` | choice | Built-in model (ENGRO2, Recon, HMRcore) | |
| 25 | 24 |
| 26 ### Optional Parameters | 25 ### Optional Parameters |
| 27 | 26 |
| 28 | Parameter | Short | Type | Default | Description | | 27 | Parameter | Short | Type | Default | Description | |
| 29 |-----------|--------|------|---------|-------------| | 28 |-----------|--------|------|---------|-------------| |
| 29 | `--tool_dir` | `-td` | string | auto-detected | COBRAxy installation directory (automatically detected after pip install) | | |
| 30 | `--none` | `-n` | boolean | true | Handle missing gene values | | 30 | `--none` | `-n` | boolean | true | Handle missing gene values | |
| 31 | `--model_upload` | `-rl` | file | - | Custom GPR rules file | | 31 | `--model_upload` | `-rl` | file | - | Custom GPR rules file | |
| 32 | `--model_upload_name` | `-rn` | string | - | Custom model name | | 32 | `--model_upload_name` | `-rn` | string | - | Custom model name | |
| 33 | `--out_log` | - | file | log.txt | Output log file | | 33 | `--out_log` | - | file | log.txt | Output log file | |
| 34 | |
| 35 > **Note**: After installing COBRAxy via pip, the `--tool_dir` parameter is automatically detected and doesn't need to be specified. | |
| 34 | 36 |
| 35 ## Input Format | 37 ## Input Format |
| 36 | 38 |
| 37 ### Gene Expression File | 39 ### Gene Expression File |
| 38 ```tsv | 40 ```tsv |
| 100 ## Usage Examples | 102 ## Usage Examples |
| 101 | 103 |
| 102 ### Command Line | 104 ### Command Line |
| 103 | 105 |
| 104 ```bash | 106 ```bash |
| 105 # Basic usage with built-in model | 107 # Basic usage with built-in model (after pip install) |
| 106 ras_generator -td /path/to/COBRAxy \ | 108 ras_generator \ |
| 107 -in expression_data.tsv \ | 109 -in expression_data.tsv \ |
| 108 -ra ras_output.tsv \ | 110 -ra ras_output.tsv \ |
| 109 -rs ENGRO2 | 111 -rs ENGRO2 |
| 110 | 112 |
| 111 # With custom model and strict missing gene handling | 113 # With custom model and strict missing gene handling |
| 112 ras_generator -td /path/to/COBRAxy \ | 114 ras_generator \ |
| 113 -in expression_data.tsv \ | 115 -in expression_data.tsv \ |
| 114 -ra ras_output.tsv \ | 116 -ra ras_output.tsv \ |
| 115 -rl custom_rules.tsv \ | 117 -rl custom_rules.tsv \ |
| 116 -rn "CustomModel" \ | 118 -rn "CustomModel" \ |
| 117 -n false | 119 -n false |
| 118 ``` | 120 |
| 119 | 121 # Explicitly specify tool directory (only needed if not using pip install) |
| 120 ### Python API | 122 ras_generator -td /path/to/COBRAxy \ |
| 121 | 123 -in expression_data.tsv \ |
| 122 ```python | 124 -ra ras_output.tsv \ |
| 123 import ras_generator | 125 -rs ENGRO2 |
| 124 | |
| 125 # Basic RAS generation | |
| 126 args = [ | |
| 127 '-td', '/path/to/COBRAxy', | |
| 128 '-in', 'expression_data.tsv', | |
| 129 '-ra', 'ras_output.tsv', | |
| 130 '-rs', 'ENGRO2' | |
| 131 ] | |
| 132 | |
| 133 ras_generator.main(args) | |
| 134 ``` | 126 ``` |
| 135 | 127 |
| 136 ### Galaxy Usage | 128 ### Galaxy Usage |
| 137 | 129 |
| 138 1. Upload gene expression file to Galaxy | 130 1. Upload gene expression file to Galaxy |
