Skip to content

Commit

Permalink
Use CDSpos instead of cDNApos
Browse files Browse the repository at this point in the history
  • Loading branch information
frewmack committed Jan 14, 2025
1 parent e2ffc77 commit e76e161
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ const annotate = timeit('annotateCadd')(

if (key in annotationKeys) {
/* eslint-disable-next-line @typescript-eslint/no-unused-vars */
const { aaAlt, aaPos, aaRef, cdnaPos, chrom, pos, alt, ref, ...rest } = annotationKeys[key];
const { aaAlt, aaPos, aaRef, cdsPos, chrom, pos, alt, ref, ...rest } = annotationKeys[key];
response.variant.info = {
...response.variant.info,
aaChange:
Expand All @@ -42,7 +42,8 @@ const annotate = timeit('annotateCadd')(
aaAlt === aaRef ? '=' : AMINO_ACID_MAPPING[aaAlt]
}`
: 'NA',
cdna: alt && cdnaPos && cdnaPos !== 'NA' && ref ? `c.${cdnaPos}${ref}>${alt}` : 'NA',
// uses CDSpos instead of cDNApos
cdna: alt && cdsPos && cdsPos !== 'NA' && ref ? `c.${cdsPos}${ref}>${alt}` : 'NA',
...rest,
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@ const _getAnnotations = async (position: string, assemblyId: string) => {
oAA: 17
nAA: 18
FeatureID: 20
cDNApos: 25
cDNApos: 25 // deprecated for use in OSMP
CDSpos: 27 // replaces cDNApos
protpos: 29
spliceAI-acc-gain: 94 (GRCh37) 109 (GRCh38)
spliceAI-acc-loss: 95 (GRCh37) 110 (GRCh38)
Expand All @@ -95,7 +96,7 @@ const _formatAnnotations = (annotations: string[], assemblyId: string) => {
['aaRef', 16],
['aaAlt', 17],
['transcript', 19],
['cdnaPos', 24],
['cdsPos', 26], // actually CDSpos
['aaPos', 28],
['phred', assemblyId === 'GRCh37' ? 115 : 133],
];
Expand Down
2 changes: 1 addition & 1 deletion server/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ export interface CaddAnnotation extends VariantCoordinate {
aaAlt: string;
aaPos: string;
aaRef: string;
cdnaPos: string;
cdsPos: string;
consequence: string;
consScore: number;
phred: number;
Expand Down

0 comments on commit e76e161

Please sign in to comment.