For one of my samples, I have two runs.

    sample1
    +-- run1/
    |   +-- *.bax.h5
    +-- run2/
        +-- *.bax.h5

My workflow involves using **bax2bam** to convert *.bax.h5* to *unaligned bam*. Then using **pbalign** to convert *unaligned bam* to *aligned bam*.

How do I combine these two runs into one sample? And at what point in my workflow do i do that?
I managed to get it to work. Not sure if this is the best way.

I converted `*.bax.h5` to BAM separately for each run. 

    bax2bam -o "sample1_run1" $(find . -name "*.bax.h5")
    bax2bam -o "sample1_run2" $(find . -name "*.bax.h5")

This creates scraps and subreads BAM files. I merged the subreads BAMs.

    samtools merge sample1.bam sample1_run1.subreads.bam sample1_run2.subreads.bam

Then created the **.pbi** index file using SMRT/5.0.1

    pbindex sample1.bam