Is there something like amos Hawkeye for any assembly fasta file??
Unconfigured Ad
Collapse
X
-
Sphil.. do you have a R script for this lying around that you can post here.
I got this after hours of google-ing:
library(lattice)
data<-read.table("contigs.bases.sizes")
y=t(data[2])
myhist <- function(x, ..., breaks="Sturges",
main = paste("Histogram of", xname),
xlab = xname,
ylab = "Frequency") {
xname = paste(deparse(substitute(x), 500), collapse="\n")
h = hist(x, breaks=breaks, plot=FALSE)
plot(h$breaks, c(NA,h$counts), type='S', main=main,
xlab=xlab, ylab=ylab, axes=FALSE, ...)
axis(1)
axis(2)
lines(h$breaks, c(h$counts,NA), type='s')
lines(h$breaks, c(NA,h$counts), type='h')
lines(h$breaks, c(h$counts,NA), type='h')
lines(h$breaks, rep(0,length(h$breaks)), type='S')
invisible(h)
}
myhist(y,log="y",breaks=100,xlab="contig length(bp)")
q()
But this does not give any control over size of the histogram bin or any way to color bins by number of N's in them. I am not a R expert, can someone help me out?
Thanks!
Comment
-
Hey,
I still often do this the old-school way, using the count_fasta.pl perl-script of Joseph Fass. http://wiki.bioinformatics.ucdavis.e...Count_fasta.pl
Usage for bin-width of 20:
This gives you a histogram table you can use to visualize in your preferred spreadsheet software. Furthermore it provides information about N50 and GC content, which is useful for judging the assembly quality.Code:perl count_fasta.pl -i 20 infile.fasta
Best,
Simon
Edit:
No support for differential coloring within the script, of course.
Comment
Latest Articles
Collapse
-
by SEQadmin2
CRISPR/Cas9 sparked the gene editing revolution for both research and therapeutics.1 But this system still showed severe issues that limited its applications. The most prominent were the heavy reliance on PAM sequences, delivery limitations, double-stranded breaks that prompt unintended edits and cell death, and editing inefficiency (both in targeting and in knock-in reliability).
Despite this, “CRISPR helped turn genome editing from a specialized technique into...-
Channel: Articles
07-31-2026, 11:01 AM -
ad_right_rmr
Collapse
News
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by SEQadmin2, 08-20-2026, 11:17 AM
|
0 responses
11 views
0 reactions
|
Last Post
by SEQadmin2
08-20-2026, 11:17 AM
|
||
|
Started by SEQadmin2, 08-18-2026, 10:05 AM
|
0 responses
20 views
0 reactions
|
Last Post
by SEQadmin2
08-18-2026, 10:05 AM
|
||
|
Started by SEQadmin2, 08-13-2026, 12:22 PM
|
0 responses
41 views
0 reactions
|
Last Post
by SEQadmin2
08-13-2026, 12:22 PM
|
||
|
Started by SEQadmin2, 08-11-2026, 10:35 AM
|
0 responses
32 views
0 reactions
|
Last Post
by SEQadmin2
08-11-2026, 10:35 AM
|
Comment