# Homologous Recombination Deficiency

DRAGEN Homologous Recombination Deficiency (HRD) Scoring takes in allele-specific copy number calls in either VCF format or directly streamed from somatic copy number callers. DRAGEN HRD then calculates scores for Loss of Heterozygosity (LOH), Telomeric Allelic Imbalance (TAI), and Large-Scale State Transition (LST). The three scores are output to the `.hrdscore.csv` file. You can only use DRAGEN HRD when inputting results from WGS somatic CNV calling or ASCN WES somatic CNV calling.

![](https://3660538983-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FpFn0gLe5V859SXejQNAW%2Fuploads%2Fgit-blob-f01ee5028eab8168f44da312077a5add4a295a4b%2FHRD_Workflow.png?alt=media)

## Command-Line Options

Use the following command-line options to run HRD scoring. You can run HRD scoring with somatic CNV calling or after using somatic CNV calling results.

To run HRD scoring together with somatic CNV calling, use the following options. For more CNV parameters, please refer to CNV calling.

`--enable-hrd=true` Set to true to enable HRD scoring to quantify genomic instability.

`--enable-cnv=true` Set to true to enable CNV calling to run together with HRD scoring.

To run HRD scoring after somatic CNV calling, use the following options:

`--enable-hrd=true` Set to true to enable HRD scoring to quantify genomic instability.

`--hrd-input-ascn` Specify the allele-specific copy number file (`*cnv.vcf.gz`). The CNV VCF file should include `REF` calls for proper HRD segmentation. See the option `--cnv-enable-ref-calls` in the CNV section.

`--hrd-input-tn` Specify the tumor normalized bin count file (`*.tn.tsv.gz`).

If reference is failed to `AutoDetected`, then centromere and blacklist files should be specified with following options:

`--hrd-input-centromere` Centromere locations per chromosome in tsv format

`--hrd-input-blacklist` Blacklist bed file

## HRD Output

The following metrics are included in the `.hrdscore.csv` output file. The following is an example output file.

| Sample | LOH\_Score | TAI\_Score | LST\_Score | HRD\_Score |
| ------ | :--------: | :--------: | :--------: | :--------: |
| Sample |     16     |     17     |     28     |     61     |

## Example command line

The following example command runs HRD end to end workflow with CNV. This is an example of Somatic WGS T/N. See the Somatic CNV section for other use cases. HRD is supported for any CNV workflows that support ASCN, and just needs to add `--enable-hrd=true` on top of the CNV command lines.

```
dragen \
-r <HASH_TABLE> \
--tumor-bam-input <TUMOR_BAM> \
--cnv-normal-b-allele-vcf <NORMAL_VCF> \
--output-directory <OUTPUT> \
--output-file-prefix <SAMPLE> \
--enable-map-align=false \
--enable-cnv=true \
--enable-hrd=true \
```

The following example command runs HRD standalone.

```
dragen \
-r <HASH_TABLE> \
--hrd-input-ascn <CNV_VCF> \
--hrd-input-tn <TN_TSV> \
--output-directory <OUTPUT> \
--output-file-prefix <SAMPLE> \
--enable-hrd=true \
```
