This repository has been archived by the owner on Aug 30, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4540532
commit a0942f2
Showing
14 changed files
with
2,860 additions
and
2,059 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,94 +1,98 @@ | ||
<template> | ||
<fdrplot | ||
ref='fdrRef' | ||
id='geneFDR' | ||
:height='"300px"' | ||
:data='geneFdrModel' | ||
:targetName='targetName' | ||
:targetPosition='targetScore' | ||
:decoyPosition='decoyScore' | ||
:enrichment='enrichment' | ||
:qValue='qValue' | ||
:xAxisLabel='"protein score (best Q-score)"' | ||
:yAxisLabel='"# of proteins"' | ||
ref="fdrRef" | ||
id="geneFDR" | ||
:height="'300px'" | ||
:data="geneFdrModel" | ||
:targetName="targetName" | ||
:targetPosition="targetScore" | ||
:decoyPosition="decoyScore" | ||
:enrichment="enrichment" | ||
:qValue="qValue" | ||
:xAxisLabel="'protein score (best Q-score)'" | ||
:yAxisLabel="'# of proteins'" | ||
/> | ||
</template> | ||
|
||
<script> | ||
import axios from 'axios' | ||
import fdrplot from '@/vue-d3-components/FDRGraph' | ||
import axios from "axios"; | ||
import fdrplot from "@/vue-d3-components/FDRGraph"; | ||
export default { | ||
name: 'geneFdrPlot', | ||
name: "geneFdrPlot", | ||
components: { | ||
fdrplot: fdrplot | ||
fdrplot: fdrplot, | ||
}, | ||
props: { | ||
minWidth: { | ||
type: Number, | ||
default: 400 | ||
default: 400, | ||
}, | ||
minHeight: { | ||
type: Number, | ||
default: 400 | ||
default: 400, | ||
}, | ||
proteinId: { | ||
type: String, | ||
default: null | ||
default: null, | ||
}, | ||
targetName: { | ||
type: String, | ||
default: null | ||
} | ||
default: null, | ||
}, | ||
}, | ||
data: function () { | ||
return { | ||
geneFdrModel: null, | ||
targetScore: null, | ||
decoyScore: null, | ||
enrichment: null, | ||
qValue: null | ||
} | ||
}, | ||
computed: { | ||
}, | ||
watch: { | ||
qValue: null, | ||
}; | ||
}, | ||
computed: {}, | ||
watch: {}, | ||
methods: { | ||
getData: function () { | ||
let that = this | ||
getData: function () { | ||
let that = this; | ||
let urlDatasets = this.$store.state.host+'/proteomicsdb/logic/fdr/getGeneFDR.xsjs' | ||
axios.get(urlDatasets, { | ||
let urlDatasets = | ||
this.$store.state.host + "/proteomicsdb/logic/fdr/getGeneFDR.xsjs"; | ||
axios | ||
.get(urlDatasets, { | ||
params: { | ||
proteinId: this.proteinId | ||
}}) | ||
.then(function (response) { | ||
that.geneFdrModel = response.data | ||
proteinId: this.proteinId, | ||
}, | ||
}) | ||
.then(function (response) { | ||
that.geneFdrModel = response.data; | ||
}); | ||
}, | ||
getGeneScores: function () { | ||
let that = this | ||
getGeneScores: function () { | ||
let that = this; | ||
let urlDatasets = this.$store.state.host+'/proteomicsdb/logic/fdr/getGeneFDRScore.xsjs' | ||
axios.get(urlDatasets, { | ||
let urlDatasets = | ||
this.$store.state.host + "/proteomicsdb/logic/fdr/getGeneFDRScore.xsjs"; | ||
axios | ||
.get(urlDatasets, { | ||
params: { | ||
proteinId: this.proteinId | ||
}}) | ||
.then(function (response) { | ||
that.targetScore = response.data.TARGET.SCORE | ||
that.decoyScore = response.data.DECOY.SCORE | ||
that.enrichment = response.data.enrichment | ||
that.qValue = response.data.Q_VALUE | ||
proteinId: this.proteinId, | ||
}, | ||
}) | ||
.then(function (response) { | ||
that.targetScore = response.data.TARGET.SCORE; | ||
that.decoyScore = response.data.DECOY.SCORE; | ||
that.enrichment = response.data.enrichment; | ||
that.qValue = response.data.Q_VALUE; | ||
}); | ||
}, | ||
getSVG: function() { | ||
getSVG: function () { | ||
return this.$refs.fdrRef.getSVG(); | ||
} | ||
}, | ||
}, | ||
mounted() { | ||
this.getData() | ||
this.getGeneScores() | ||
} | ||
} | ||
this.getData(); | ||
this.getGeneScores(); | ||
}, | ||
}; | ||
</script> |
Oops, something went wrong.