When your genome is one of the
hosted hubs, JBrowseR("hg38") is all you need. This
tutorial covers the other case: building a browser for a genome you host
yourself, with your own tracks, gene-name search, and theme.
assembly() builds the reference from a FASTA URL.
JBrowse derives the index locations (.fai, plus
.gzi for bgzipped FASTA) from the URL, so you only point at
the FASTA itself. Add reference-name aliases so
chr1/1 both resolve.
track() infers the track type and adapter from the file
extension. Group your tracks with tracks(). You do not need
to set assemblyNames on each track —
JBrowseR() fills it in from the assembly you load.
Hub assemblies include search; for a custom assembly, point at your
own Trix index files with text_index() and pass it as
text_search. Now location can be a gene
name.
track_data_frame() turns a data frame into an in-browser
track with no files and no server — the natural way to put an analysis
you ran in R onto the genome. The frame needs chrom,
start, end, and name columns; an
optional score column makes it a quantitative track.
When rendered inside Shiny, clicking a feature sets
input$selectedFeature to the feature’s data, so you can
build tables, plots, or links from the current selection.