> For the complete documentation index, see [llms.txt](https://yuting0103.gitbook.io/quantbrains/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://yuting0103.gitbook.io/quantbrains/jing-tai-hui-ce-fan-li/qb_static_backtest_pass/feng-xian-wei-jie-lv-jing-fan-li-yi.md).

# 風險位階（濾鏡範例一)

**風險位階(RiskLevel)**

計算對象：原始策略的損益走勢（i\_OpenEquity）

\
概念可參考之前的文章 ["如何知道目前的進場風險跟優勢位階"](http://quantbrains.club/phpBB32/viewtopic.php?f=5\&t=163)\
\
可直接參考源碼，源碼內我們透過 centerpos 來做為一個長期(一年內)的軸心價格參考，yeasSTD為年標準差，\
我們取上下各兩倍標準差作為走勢範圍的估計\
對多單來說，越接近上緣越高風險，縮減資金分配權重，越接近下緣越高優勢，增加資金分配權重\
對空單來說，則反過來
