Mercurial > repos > iuc > episcanpy_cluster_embed
comparison cluster_embed.xml @ 1:51dbb534fbce draft default tip
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/episcanpy/ commit bb79cb8cad3bc1433bff7caf9d7b45e7993dd470
| author | iuc |
|---|---|
| date | Sat, 22 Apr 2023 12:13:18 +0000 |
| parents | 43711b22f28b |
| children |
comparison
equal
deleted
inserted
replaced
| 0:43711b22f28b | 1:51dbb534fbce |
|---|---|
| 44 copy=False, | 44 copy=False, |
| 45 method='$method.rank_features_method', | 45 method='$method.rank_features_method', |
| 46 corr_method='$method.rank_features_corr_method' | 46 corr_method='$method.rank_features_corr_method' |
| 47 ) | 47 ) |
| 48 | 48 |
| 49 #else if $method.method == 'tl.find_genes' | |
| 50 esc.tl.find_genes( | |
| 51 adata, | |
| 52 gtf_file='$method.find_genes_gtf_file', | |
| 53 key_added='$method.find_genes_key_added', | |
| 54 upstream=$method.find_genes_upstream, | |
| 55 feature_type='$method.find_genes_feature_type', | |
| 56 annotation='$method.find_genes_annotation', | |
| 57 raw=$method.find_genes_raw) | |
| 58 | |
| 59 #else if $method.method == 'tl.get_n_clusters' | 49 #else if $method.method == 'tl.get_n_clusters' |
| 60 esc.tl.getNClusters( | 50 esc.tl.getNClusters( |
| 61 adata, | 51 adata, |
| 62 n_cluster=$method.get_n_clusters_n_cluster, | 52 n_cluster=$method.get_n_clusters_n_cluster, |
| 63 range_min=$method.get_n_clusters_range_min, | 53 range_min=$method.get_n_clusters_range_min, |
| 86 <expand macro="inputs_anndata"/> | 76 <expand macro="inputs_anndata"/> |
| 87 <conditional name="method"> | 77 <conditional name="method"> |
| 88 <param argument="method" type="select" label="Method used for Clustering or Embedding"> | 78 <param argument="method" type="select" label="Method used for Clustering or Embedding"> |
| 89 <option value="pp.lazy">Embedding: Automatically compute PCA coordinates, loadings and variance decomposition, a neighborhood graph of observations, t-distributed stochastic neighborhood embedding (tSNE) Uniform Manifold Approximation and Projection (UMAP), using 'pp.lazy'</option> | 79 <option value="pp.lazy">Embedding: Automatically compute PCA coordinates, loadings and variance decomposition, a neighborhood graph of observations, t-distributed stochastic neighborhood embedding (tSNE) Uniform Manifold Approximation and Projection (UMAP), using 'pp.lazy'</option> |
| 90 <option value="tl.rank_features">Rank features for characterizing groups, using 'tl.rank_features'</option> | 80 <option value="tl.rank_features">Rank features for characterizing groups, using 'tl.rank_features'</option> |
| 91 <option value="tl.find_genes">Embedding: Find genes and add annotations, using 'pp.find_genes'</option> | |
| 92 <option value="tl.get_n_clusters">Clustering: Test different settings of louvain to obtain the target number of clusters, using 'tl.getNClusters'</option> | 81 <option value="tl.get_n_clusters">Clustering: Test different settings of louvain to obtain the target number of clusters, using 'tl.getNClusters'</option> |
| 93 <option value="tl.kmeans">Clustering: Compute kmeans clustering using X_pca fits, using 'tl.kmeans'</option> | 82 <option value="tl.kmeans">Clustering: Compute kmeans clustering using X_pca fits, using 'tl.kmeans'</option> |
| 94 <option value="tl.hc">Clustering: Compute hierarchical clustering using X_pca fits, using 'tl.hc'</option> | 83 <option value="tl.hc">Clustering: Compute hierarchical clustering using X_pca fits, using 'tl.hc'</option> |
| 95 </param> | 84 </param> |
| 96 <when value="pp.lazy"> | 85 <when value="pp.lazy"> |
| 211 <param name="rank_features_corr_method" value="benjamini-hochberg" type="select" label="p-value correction method" help="(corr_method)"> | 200 <param name="rank_features_corr_method" value="benjamini-hochberg" type="select" label="p-value correction method" help="(corr_method)"> |
| 212 <option value="benjamini-hochberg">Benjamini Hochberg</option> | 201 <option value="benjamini-hochberg">Benjamini Hochberg</option> |
| 213 <option value="bonferroni">Bonferroni</option> | 202 <option value="bonferroni">Bonferroni</option> |
| 214 </param> | 203 </param> |
| 215 </when> | 204 </when> |
| 216 <when value="tl.find_genes"> | |
| 217 <param name="find_genes_gtf_file" type="data" format="gtf" label="Annotation GTF file" help="(gtf_file)"/> | |
| 218 <param name="find_genes_key_added" value="transcript_annotation" type="text" label="Key added" help="(key_added)"> | |
| 219 <sanitizer invalid_char=""> | |
| 220 <valid initial="string.letters,string.digits"> | |
| 221 <add value="_" /> | |
| 222 <add value="-" /> | |
| 223 <add value="." /> | |
| 224 <add value=" " /> | |
| 225 <add value="," /> | |
| 226 </valid> | |
| 227 </sanitizer> | |
| 228 <validator type="regex">[0-9a-zA-Z_., -]+</validator> | |
| 229 </param> | |
| 230 <param name="find_genes_upstream" value="2000" min="0" type="integer" label="Upstream" help="(upstream)"/> | |
| 231 <param name="find_genes_feature_type" value="transcript" type="text" label="Feature type" help="(feature_type)"> | |
| 232 <sanitizer invalid_char=""> | |
| 233 <valid initial="string.letters,string.digits"> | |
| 234 <add value="_" /> | |
| 235 <add value="-" /> | |
| 236 <add value="." /> | |
| 237 <add value=" " /> | |
| 238 <add value="," /> | |
| 239 </valid> | |
| 240 </sanitizer> | |
| 241 <validator type="regex">[0-9a-zA-Z_., -]+</validator> | |
| 242 </param> | |
| 243 <param name="find_genes_annotation" value="HAVANA" type="text" label="Annotation" help="(annotation)"> | |
| 244 <sanitizer invalid_char=""> | |
| 245 <valid initial="string.letters,string.digits"> | |
| 246 <add value="_" /> | |
| 247 <add value="-" /> | |
| 248 <add value="." /> | |
| 249 <add value=" " /> | |
| 250 <add value="," /> | |
| 251 </valid> | |
| 252 </sanitizer> | |
| 253 <validator type="regex">[0-9a-zA-Z_., -]+</validator> | |
| 254 </param> | |
| 255 <param name="find_genes_raw" type="select" label="Raw?" help="(raw)"> | |
| 256 <option value="True">True</option> | |
| 257 <option value="False" selected="true">False</option> | |
| 258 </param> | |
| 259 </when> | |
| 260 <when value="tl.get_n_clusters"> | 205 <when value="tl.get_n_clusters"> |
| 261 <param name="get_n_clusters_n_cluster" value="14" min="1" type="integer" label="Number of clusters" help="(n_cluster)"/> | 206 <param name="get_n_clusters_n_cluster" value="14" min="1" type="integer" label="Number of clusters" help="(n_cluster)"/> |
| 262 <param name="get_n_clusters_method" type="select" label="Clustering method to use" help="(method)"> | 207 <param name="get_n_clusters_method" type="select" label="Clustering method to use" help="(method)"> |
| 263 <option value="leiden" selected="true">leiden</option> | 208 <option value="leiden" selected="true">leiden</option> |
| 264 <option value="louvain">louvain</option> | 209 <option value="louvain">louvain</option> |
| 291 <outputs> | 236 <outputs> |
| 292 <expand macro="anndata_outputs"/> | 237 <expand macro="anndata_outputs"/> |
| 293 </outputs> | 238 </outputs> |
| 294 <tests> | 239 <tests> |
| 295 <test expect_num_outputs="2"> | 240 <test expect_num_outputs="2"> |
| 296 <!-- test 0- pp.lazy --> | 241 <!-- pp.lazy --> |
| 297 <param name="adata" value="krumsiek11.h5ad" /> | 242 <param name="adata" value="krumsiek11.h5ad" /> |
| 298 <conditional name="method"> | 243 <conditional name="method"> |
| 299 <param name="method" value="pp.lazy"/> | 244 <param name="method" value="pp.lazy"/> |
| 300 <param name="lazy_pp_pca" value="True"/> | 245 <param name="lazy_pp_pca" value="True"/> |
| 301 <param name="lazy_svd_solver" value="arpack"/> | 246 <param name="lazy_svd_solver" value="arpack"/> |
| 320 </assert_contents> | 265 </assert_contents> |
| 321 </output> | 266 </output> |
| 322 <output name="anndata_out" file="krumsiek11.pp.lazy.h5ad" ftype="h5ad" compare="sim_size"/> | 267 <output name="anndata_out" file="krumsiek11.pp.lazy.h5ad" ftype="h5ad" compare="sim_size"/> |
| 323 </test> | 268 </test> |
| 324 <test expect_num_outputs="2"> | 269 <test expect_num_outputs="2"> |
| 325 <!-- test 1- tl.rank_features --> | 270 <!-- tl.rank_features --> |
| 326 <param name="adata" value="krumsiek11.pp.lazy.tl.louvain.h5ad" /> | 271 <param name="adata" value="krumsiek11.pp.lazy.tl.louvain.h5ad" /> |
| 327 <conditional name="method"> | 272 <conditional name="method"> |
| 328 <param name="method" value="tl.rank_features"/> | 273 <param name="method" value="tl.rank_features"/> |
| 329 <param name="rank_features_groupby" value="louvain"/> | 274 <param name="rank_features_groupby" value="louvain"/> |
| 330 <param name="rank_features_use_raw" value="False"/> | 275 <param name="rank_features_use_raw" value="False"/> |
| 343 <assert_contents> | 288 <assert_contents> |
| 344 <has_h5_keys keys="obs, uns, obsm, varm, obsp" /> | 289 <has_h5_keys keys="obs, uns, obsm, varm, obsp" /> |
| 345 </assert_contents> | 290 </assert_contents> |
| 346 </output> | 291 </output> |
| 347 </test> | 292 </test> |
| 348 <test expect_num_outputs="2"> | 293 <test expect_num_outputs="2"> |
| 349 <!-- test 2-tl.find_genes --> | 294 <!-- tl.get_n_clusters --> |
| 350 <param name="adata" value="chrY.h5ad" /> | |
| 351 <conditional name="method"> | |
| 352 <param name="method" value="tl.find_genes"/> | |
| 353 <param name="find_genes_gtf_file" value="chrY.gtf"/> | |
| 354 <param name="find_genes_key_added" value="transcript_annotation"/> | |
| 355 <param name="find_genes_upstream" value="2000"/> | |
| 356 <param name="find_genes_feature_type" value="transcript"/> | |
| 357 <param name="find_genes_annotation" value="HAVANA"/> | |
| 358 <param name="find_genes_raw" value="False"/> | |
| 359 </conditional> | |
| 360 <section name="advanced_common"> | |
| 361 <param name="show_log" value="true" /> | |
| 362 </section> | |
| 363 <output name="anndata_out" file="chrY_with_transcript_annotation.h5ad" ftype="h5ad" compare="sim_size"> | |
| 364 <assert_contents> | |
| 365 <has_h5_keys keys="var" /> | |
| 366 </assert_contents> | |
| 367 </output> | |
| 368 </test> | |
| 369 <test expect_num_outputs="2"> | |
| 370 <!-- test 3-tl.get_n_clusters --> | |
| 371 <param name="adata" value="krumsiek11.pp.lazy.tl.louvain.h5ad" /> | 295 <param name="adata" value="krumsiek11.pp.lazy.tl.louvain.h5ad" /> |
| 372 <conditional name="method"> | 296 <conditional name="method"> |
| 373 <param name="method" value="tl.get_n_clusters"/> | 297 <param name="method" value="tl.get_n_clusters"/> |
| 374 <param name="get_n_clusters_n_clusters" value="3"/> | 298 <param name="get_n_clusters_n_clusters" value="3"/> |
| 375 <param name="get_n_clusters_method" value="louvain"/> | 299 <param name="get_n_clusters_method" value="louvain"/> |
| 384 <param name="show_log" value="true" /> | 308 <param name="show_log" value="true" /> |
| 385 </section> | 309 </section> |
| 386 <output name="anndata_out" file="krumsiek11.tl.get_n_clusters.h5ad" ftype="h5ad"/> | 310 <output name="anndata_out" file="krumsiek11.tl.get_n_clusters.h5ad" ftype="h5ad"/> |
| 387 </test> | 311 </test> |
| 388 <test expect_num_outputs="2"> | 312 <test expect_num_outputs="2"> |
| 389 <!-- test 4-tl.kmeans --> | 313 <!-- tl.kmeans --> |
| 390 <param name="adata" value="krumsiek11.pp.lazy.h5ad" /> | 314 <param name="adata" value="krumsiek11.pp.lazy.h5ad" /> |
| 391 <conditional name="method"> | 315 <conditional name="method"> |
| 392 <param name="method" value="tl.kmeans"/> | 316 <param name="method" value="tl.kmeans"/> |
| 393 <param name="kmeans_num_clusters" value="14"/> | 317 <param name="kmeans_num_clusters" value="14"/> |
| 394 </conditional> | 318 </conditional> |
| 396 <param name="show_log" value="true" /> | 320 <param name="show_log" value="true" /> |
| 397 </section> | 321 </section> |
| 398 <output name="anndata_out" file="krumsiek11.tl.kmeans.h5ad" ftype="h5ad"/> | 322 <output name="anndata_out" file="krumsiek11.tl.kmeans.h5ad" ftype="h5ad"/> |
| 399 </test> | 323 </test> |
| 400 <test expect_num_outputs="2"> | 324 <test expect_num_outputs="2"> |
| 401 <!-- test 5-tl.hc --> | 325 <!-- tl.hc --> |
| 402 <param name="adata" value="krumsiek11.pp.lazy.h5ad" /> | 326 <param name="adata" value="krumsiek11.pp.lazy.h5ad" /> |
| 403 <conditional name="method"> | 327 <conditional name="method"> |
| 404 <param name="method" value="tl.hc"/> | 328 <param name="method" value="tl.hc"/> |
| 405 <param name="hc_num_clusters" value="14"/> | 329 <param name="hc_num_clusters" value="14"/> |
| 406 </conditional> | 330 </conditional> |
| 417 This function automatically computes PCA coordinates, loadings and variance decomposition, a neighborhood graph of | 341 This function automatically computes PCA coordinates, loadings and variance decomposition, a neighborhood graph of |
| 418 observations, t-distributed stochastic neighborhood embedding (tSNE) Uniform Manifold Approximation and Projection (UMAP). | 342 observations, t-distributed stochastic neighborhood embedding (tSNE) Uniform Manifold Approximation and Projection (UMAP). |
| 419 | 343 |
| 420 More details on the `episcanpy documentation | 344 More details on the `episcanpy documentation |
| 421 <https://colomemaria.github.io/episcanpy_doc/api/episcanpy.api.pp.lazy.html>`__ | 345 <https://colomemaria.github.io/episcanpy_doc/api/episcanpy.api.pp.lazy.html>`__ |
| 422 | |
| 423 Find and add gene annotations (`tl.find_genes`) | |
| 424 ======================================================================================== | |
| 425 This function adds a gene annotation to an AnnData (h5ad) file from annotations file (.annotation.gtf). | |
| 426 | 346 |
| 427 Automatically obtain target number of clusters (`tl.getNClusters`) | 347 Automatically obtain target number of clusters (`tl.getNClusters`) |
| 428 ======================================================================================== | 348 ======================================================================================== |
| 429 This function will test different settings of louvain to obtain the target number of clusters. | 349 This function will test different settings of louvain to obtain the target number of clusters. |
| 430 | 350 |
