Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
alstat committed Jul 11, 2022
1 parent 8dfdf8a commit f8d3351
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions docs/src/man/text_alignment.md
Original file line number Diff line number Diff line change
Expand Up @@ -334,19 +334,19 @@ Finally, we can run the alignment for the first 20 milestones of macarif, and fi
res, scr = align(eref[1:20], etgt[1:30]);
```
We can then plot the heatmap of the scores:
```@repl hij
```@example hij
using CairoMakie
fig, ax, hm = heatmap(1:size(scr, 1), 1:size(scr, 2), scr);
Colorbar(fig[:, end+1], hm)
fig
```
The x-axis contains the index of the reference milestones, and the y-axis contains the target milestone indices. We can plot the alignment of first milestone of reference against first milestone of target
```@repl hij
using CairoMakie
```@example hij
f1, a1, xy1 = plot(res[1,1], :insertions)
f1
```
Finally, to plot all the milestones in one figure, we first filter the scores to those with lower scores or distances, so that we'll have milestones that are indeed similar.
```@repl hij
```@example hij
idx = findmin(scr, dims=2)[2][findmin(scr, dims=2)[1] .< 1150]
f2, a2, xy2 = plot(res, idx; midstyles=(color=(:red, 0.7), linewidth=0.1))
f2
Expand Down

0 comments on commit f8d3351

Please sign in to comment.