### Run Generic Exon Example Source: https://github.com/wheretrue/exon/blob/main/exon-examples/README.md This command provides the general syntax for running any example included in the Exon crate. Users should replace '' with the specific example they wish to execute. ```bash cargo run --example ``` -------------------------------- ### Run Specific Exon Example (gff_annotation_join) Source: https://github.com/wheretrue/exon/blob/main/exon-examples/README.md This command demonstrates how to run a specific example from the Exon crate, in this case, the 'gff_annotation_join' example. It illustrates the concrete application of the generic run command. ```bash cargo run --example gff_annotation_join ``` -------------------------------- ### Install exonr R Package Source: https://github.com/wheretrue/exon/blob/main/exon-r/README.md Installs the 'exonr' package from the r-universe repository. The second repository, 'https://cloud.r-project.org', is included as a fallback or for other dependencies. ```R install.packages('exonr', repos = c('https://wheretrue.r-universe.dev', 'https://cloud.r-project.org')) ``` -------------------------------- ### Install Exon Py Library using pip Source: https://github.com/wheretrue/exon/blob/main/exon-py/README.md This command installs the `exon-py` Python package from PyPI using pip, the standard package installer for Python. ```console pip install exon-py ``` -------------------------------- ### Example: Rewriting `chrom = 'chr1' AND pos BETWEEN 0 AND 1` (Mermaid) Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md A step-by-step example demonstrating the rewriting process for a complex binary expression equivalent to `chrom = 'chr1' AND pos BETWEEN 0 AND 1`. It shows the initial state and subsequent transformations using a `transform_up` approach. ```mermaid flowchart TB Z[And Binary Expression] --> A[Eq Binary Expression] Z --> U[Geq Binary Expression] U --> V[Pos Column] U --> W[Literal] A[And Binary Expression] --> B[Eq Binary Expression] A --> C[Leq Binary Expression] B --> D[Chrom Column] B --> E[Literal] C --> F[Pos Column] C --> G[Literal] ``` ```mermaid flowchart TB Z[And Binary Expression] --> A[Eq Binary Expression] Z --> U[IntervalPhysicalExpr] A[And Binary Expression] --> B[ChromPhysicalExpr] A --> C[IntervalPhysicalExpr] ``` ```mermaid flowchart TB Z[And Binary Expression] --> A[RegionPhysicalExpr] Z --> U[IntervalPhysicalExpr] ``` ```mermaid flowchart TB Z[RegionPhysicalExpr] ``` -------------------------------- ### Install Exon with Cargo Source: https://github.com/wheretrue/exon/blob/main/README.md This command adds the Exon library as a dependency to your Rust project using Cargo, Rust's package manager. It fetches the latest version from crates.io. ```bash cargo add exon ``` -------------------------------- ### VCF Expression Rewrite: Pos Column Equals Literal Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md An 'equals' binary expression with a position column and a literal is rewritten into an IntervalPhysicalExpr. For example, a literal '5' transforms into a VCF interval '5-5'. ```Mermaid flowchart TB A[Eq Binary Expression] --> B[Pos Column] A --> C[Literal] ``` ```Mermaid flowchart TB A[IntervalPhysicalExpr] ``` -------------------------------- ### VCF Expression Rewrite: Pos Column Greater Than Equal Literal Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md A 'greater than' binary expression with a position column and a literal is rewritten into an IntervalPhysicalExpr. For example, a literal '5' yields a VCF interval '5-'. This expression typically needs to be paired with a 'less than equal' expression to define a bounded interval. ```Mermaid flowchart TB A[Greater Than Binary Expression] --> B[Pos Column] A --> C[Literal] ``` ```Mermaid flowchart TB A[IntervalPhysicalExpr] ``` -------------------------------- ### Push Release Changes and Tag to Origin Source: https://github.com/wheretrue/exon/blob/main/docs/release-guide.md Pushes the committed changes to the `main` branch of the remote repository and also pushes the newly created version tag to the remote. This makes the release official and available remotely. ```bash git push origin main git push origin v$VERSION ``` -------------------------------- ### Commit Version Changes and Tag Release Source: https://github.com/wheretrue/exon/blob/main/docs/release-guide.md Stages all modified files, creates a commit message indicating the version bump, and then creates an annotated Git tag for the new release version. This step finalizes the local versioning changes. ```bash git add -u . git commit -m "release: bump to version v$VERSION" git tag -a v$VERSION -m "release: v$VERSION" ``` -------------------------------- ### Retrieve Exon Version from Cargo Metadata Source: https://github.com/wheretrue/exon/blob/main/docs/release-guide.md Retrieves the current version of the 'exon' package from the `Cargo.toml` workspace using `cargo metadata` and `jq`. The extracted version is then stored in the `VERSION` environment variable and printed to the console. ```bash VERSION=$(cargo metadata --format-version 1 | jq -r '.packages[] | select(.name == "exon") | .version') echo "Releasing v$VERSION" ``` -------------------------------- ### Bump Exon Version with Git CZ Source: https://github.com/wheretrue/exon/blob/main/docs/release-guide.md Initiates a version bump for the Exon project using `git cz bump --files-only`. This command modifies version files without creating a commit, allowing Cargo to update its lock file with the new version. ```bash git cz bump --files-only ``` -------------------------------- ### VCF File Type Detection and Scanning Flow Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md This flowchart illustrates the VCF file detection process, showing how the presence of a region filter determines whether an indexed or non-indexed VCF scanner and opener are used, ultimately leading to an asynchronous batch stream for data processing. ```Mermaid flowchart TB A[VCF File Type] --> B[VCF Table Provider] B --> C(Detect Region Filter) C -- Contains Region --> D[IndexedVCFScanner] D --> F[IndexedVCFOpener] F --> G[IndexedAsyncBatchStream] C -- Missing Filter --> E[VCFScan] E --> H[VCFOpener] H --> I[AsyncBatchStream] ``` -------------------------------- ### Rewriting Region and Interval Binary Expression (Mermaid) Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md Illustrates the transformation of a binary expression combining a RegionPhysicalExpr and an IntervalPhysicalExpr. The region's chromosome remains, and the interval is updated to the intersection of the two original intervals. ```mermaid flowchart TB A[And Binary Expression] --> B[RegionPhysicalExpr] A --> C[IntervalPhysicalExpr] ``` ```mermaid flowchart TB A[RegionPhysicalExpr] ``` -------------------------------- ### VCF Expression Rewrite: Combine Interval and Chrom Expressions Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md An 'AND' binary expression that combines an IntervalPhysicalExpr and a ChromPhysicalExpr is rewritten into a single RegionPhysicalExpr, consolidating the chromosomal and interval constraints. ```Mermaid flowchart TB A[And Binary Expression] --> B[IntervalPhysicalExpr] A --> C[Chrom Column] ``` ```Mermaid flowchart TB A[RegionPhysicalExpr] ``` -------------------------------- ### VCF Expression Rewrite: Intersect Two IntervalPhysicalExpr Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md An 'AND' binary expression involving two IntervalPhysicalExprs is rewritten into a new IntervalPhysicalExpr that represents the intersection of the two original intervals. ```Mermaid flowchart TB A[And Binary Expression] --> B[IntervalPhysicalExpr] A --> C[IntervalPhysicalExpr] ``` ```Mermaid flowchart TB A[IntervalPhysicalExpr] ``` -------------------------------- ### VCF Expression Rewrite: Pos Column Less Than Equal Literal Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md A 'less than' binary expression with a position column and a literal is rewritten into an IntervalPhysicalExpr. For instance, a literal '5' results in a VCF interval '1-5'. Note that strict less than is not supported due to the inclusive nature of VCF intervals. ```Mermaid flowchart TB A[Less Than Binary Expression] --> B[Pos Column] A --> C[Literal] ``` ```Mermaid flowchart TB A[IntervalPhysicalExpr] ``` -------------------------------- ### Rewriting Two Region Physical Expressions (Mermaid) Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md Shows the transformation of a binary expression combining two RegionPhysicalExpr expressions. The chromosome is kept if identical, otherwise the expression is false. The interval becomes the intersection of the two intervals. ```mermaid flowchart TB A[And Binary Expression] --> B[RegionPhysicalExpr] A --> C[RegionPhysicalExpr] ``` ```mermaid flowchart TB A[RegionPhysicalExpr] ``` -------------------------------- ### Rust `Interval` Struct Definition Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md Defines the `Interval` struct in Rust, which represents a genomic interval. It includes a `lower_bound` (u32) and an optional `upper_bound` (Option), with the lower bound defaulting to 1 if not explicitly known. ```rust struct Interval { lower_bound: u32, // will be 1 if not known upper_bound: Option, } ``` -------------------------------- ### VCF Expression Rewrite: Chrom Column Equals Literal Source: https://github.com/wheretrue/exon/blob/main/docs/vcf_expression_rewriting.md When an 'equals' binary expression involves a chromosome column and a literal, it is rewritten into a ChromPhysicalExpr, which represents a specific region defined by the literal. ```Mermaid flowchart TB A[Eq Binary Expression] --> B[Chrom Column] A --> C[Literal] ``` ```Mermaid flowchart TB A[ChromPhysicalExpr] ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.