nguyetdang / biograph.jl Goto Github PK
View Code? Open in Web Editor NEWA Julia package for handle genome graph in the GFA format.
Home Page: https://nguyetdang.github.io/BioGraph.jl/stable/#Description
License: MIT License
A Julia package for handle genome graph in the GFA format.
Home Page: https://nguyetdang.github.io/BioGraph.jl/stable/#Description
License: MIT License
Hi
I've been trying to get a a method working based on the test_longest_path.jl.
I'm running from a singularity container, produced from a Dockerfile with the following:
FROM ubuntu:21.04
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y dialog apt-utils julia git wget \
&& rm -rf /var/lib/apt/lists/*
RUN julia -e 'import Pkg; Pkg.add("BioGraph"); Pkg.add("Cbc"); Pkg.add("LightGraphs"); Pkg.add("Suppressor"); Pkg.precompile()'
I then run this method through Julia using one of the graphs in /test/data/
import Pkg; Pkg.add("BioGraph"); Pkg.add("Cbc"); Pkg.add("LightGraphs"); Pkg.add("Suppressor"); using BioGraph; using BioGraph: Weight, NodeLabel, EdgeLabel; using LightGraphs; using Suppressor; using Cbc; gfa_result = read_from_gfa("gfa_sample_1.gfa"); res = find_graph_component(gfa_result); longest = find_longest_path(res.graph[1], Cbc.Optimizer, is_weighted = false); final_gfa = get_gfa(longest, "out.txt");
I get this output:
Making graph
Add constraint
Solving
inter: 1, objective: 6.0, num new cycle: 0
ERROR: LoadError: MethodError: no method matching get_gfa(::BioGraph.LongestPath, ::String)
Closest candidates are:
get_gfa(::BioGraph.LongestPath; outfile) at /home/ubuntu/.julia/packages/BioGraph/N9DQS/src/longest_path.jl:167
Stacktrace:
[1] top-level scope at /data/biograph_builds/BioGraph.jl/test/data/method.jl:1
[2] include(::Function, ::Module, ::String) at ./Base.jl:380
[3] include(::Module, ::String) at ./Base.jl:368
[4] exec_options(::Base.JLOptions) at ./client.jl:296
[5] _start() at ./client.jl:506
in expression starting at /data/biograph_builds/BioGraph.jl/test/data/method.jl:1
I receive a similar error if I use get_fasta instead.
It's like the get_gfa and get_fasta functions aren't accessible.
To linearise the GFA file, should I be using a method like I'm using? I assume by passing the GFA through these functions like find_longest_path, the resulting graph will be linerised. I'm attempting to produce a method for reading in a graph produced by PGGB and writing out a linerised graph compatible with Panache.
Hi
I'm interested in using BioGraph to linearise a GFA file produced by PGGB (https://github.com/pangenome/pggb) for visualisation in Panache (https://github.com/SouthGreenPlatform/panache). I'm currently attempting to install through Julia (I'm not familiar with Julia), and I want to select a linearised representation based on a chosen reference. I was wondering if that is possible. From the documentation it only looks like the linear representation is based on the longest path in the graph. Thanks.
Writing the FASTA output considering the CIGAR string in the L-line.
** Input **
** Output **
Taking the sequence string in the S-line and their link in the L-line. A linear sequence will be generated. The mechanism is kept as in previous FASTA output, however, we have to consider the CIGAR string for overlap.
For example in the L-line having s1 + s2 + 5M, meaning that the sequence 1 (forward) and the sequence 2 (forward) are connected by a 5-nucleotide overlapped fragment. When concatenating sequence 1 and sequence 2, the overlap fragment must appear only once.
Input:
GFA file
Output:
Elements having the same index in Node Label Array, Sequence Array and Sequence Length Array are coming from the same S-line in the GFA file.
Input
Simple Graph - output of #2
Output
Input
Output
Input
Output
Input
Output
FASTA structure: There are two types of line in the FASTA file
>linear_path
ATGCATGCATGC
Direction of a DNA strand
See the last example at http://gfa-spec.github.io/GFA-spec/GFA1.html
Input
Output
Some notice:
Input
Output
In case weight value array is provided, raise warning if weight value array does not have the same size as the number of node in the simple graph.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.