main
parent
ce31f5e6ff
commit
cbb7218640
@ -0,0 +1,18 @@ |
|||||||
|
ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756) |
||||||
|
group_neutralize(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),sector) |
||||||
|
|
||||||
|
reverse(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756)) |
||||||
|
|
||||||
|
ts_rank(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),252) |
||||||
|
|
||||||
|
ts_delta(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),21) |
||||||
|
|
||||||
|
ts_zscore(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),126) |
||||||
|
|
||||||
|
multiply(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),reverse(ts_rank(fscore_momentum,63))) |
||||||
|
|
||||||
|
subtract(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),ts_mean(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),252)) |
||||||
|
|
||||||
|
divide(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),ts_std_dev(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),252)) |
||||||
|
|
||||||
|
add(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),reverse(group_rank(fscore_growth,sector))) |
||||||
@ -0,0 +1,22 @@ |
|||||||
|
ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756) |
||||||
|
reverse(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756)) |
||||||
|
ts_rank(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),252) |
||||||
|
reverse(ts_rank(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),252)) |
||||||
|
ts_zscore(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),504) |
||||||
|
reverse(ts_zscore(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),504)) |
||||||
|
subtract(ts_rank(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),126),ts_rank(ts_backfill(fscore_momentum,66),126)) |
||||||
|
reverse(subtract(ts_rank(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),126),ts_rank(ts_backfill(fscore_momentum,66),126))) |
||||||
|
ts_delta(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),63) |
||||||
|
reverse(ts_delta(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),63)) |
||||||
|
ts_sum(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),63) |
||||||
|
reverse(ts_sum(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),63)) |
||||||
|
ts_mean(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),126) |
||||||
|
reverse(ts_mean(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),126)) |
||||||
|
ts_std_dev(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),252) |
||||||
|
reverse(ts_std_dev(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),252)) |
||||||
|
group_neutralize(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),country) |
||||||
|
reverse(group_neutralize(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),country)) |
||||||
|
group_zscore(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),industry) |
||||||
|
reverse(group_zscore(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),industry)) |
||||||
|
multiply(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),reverse(ts_backfill(fscore_momentum,66))) |
||||||
|
multiply(ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756),ts_backfill(fscore_total,66)) |
||||||
@ -0,0 +1,41 @@ |
|||||||
|
subtract(implied_volatility_call_120, implied_volatility_put_90) |
||||||
|
|
||||||
|
scale(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 1) |
||||||
|
|
||||||
|
ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10) |
||||||
|
|
||||||
|
scale(divide(subtract(implied_volatility_call_120, implied_volatility_put_90), ts_mean(implied_volatility_call_120, 10)), 1) |
||||||
|
|
||||||
|
ts_sum(divide(subtract(implied_volatility_call_120, implied_volatility_put_90), ts_mean(implied_volatility_call_120, 10)), 10) |
||||||
|
|
||||||
|
scale(ts_sum(divide(subtract(implied_volatility_call_120, implied_volatility_put_90), ts_mean(implied_volatility_call_120, 10)), 10), 1) |
||||||
|
|
||||||
|
multiply(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), news_max_up_amt) |
||||||
|
|
||||||
|
scale(multiply(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), news_max_up_amt), 1) |
||||||
|
|
||||||
|
ts_zscore(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 20) |
||||||
|
|
||||||
|
scale(ts_zscore(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 20), 1) |
||||||
|
|
||||||
|
divide(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), ts_std_dev(subtract(implied_volatility_call_120, implied_volatility_put_90), 10)) |
||||||
|
|
||||||
|
scale(divide(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), ts_std_dev(subtract(implied_volatility_call_120, implied_volatility_put_90), 10)), 1) |
||||||
|
|
||||||
|
if_else(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10) > 0, ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 0) |
||||||
|
|
||||||
|
scale(if_else(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10) > 0, ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 0), 1) |
||||||
|
|
||||||
|
ts_sum(if_else(subtract(implied_volatility_call_120, implied_volatility_put_90) > 0, subtract(implied_volatility_call_120, implied_volatility_put_90), 0), 10) |
||||||
|
|
||||||
|
scale(ts_sum(if_else(subtract(implied_volatility_call_120, implied_volatility_put_90) > 0, subtract(implied_volatility_call_120, implied_volatility_put_90), 0), 10), 1) |
||||||
|
|
||||||
|
multiply(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), ts_delta(implied_volatility_call_120, 5)) |
||||||
|
|
||||||
|
scale(multiply(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), ts_delta(implied_volatility_call_120, 5)), 1) |
||||||
|
|
||||||
|
ts_sum(multiply(subtract(implied_volatility_call_120, implied_volatility_put_90), ts_delta(implied_volatility_call_120, 5)), 10) |
||||||
|
|
||||||
|
scale(ts_sum(multiply(subtract(implied_volatility_call_120, implied_volatility_put_90), ts_delta(implied_volatility_call_120, 5)), 10), 1) |
||||||
|
|
||||||
|
divide(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), ts_mean(fn_comp_not_rec_stock_options_q, 10)) |
||||||
@ -0,0 +1,39 @@ |
|||||||
|
subtract(implied_volatility_call_120, implied_volatility_put_90) |
||||||
|
|
||||||
|
ts_sum(ts_decay_linear(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 20) |
||||||
|
|
||||||
|
scale(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 1) |
||||||
|
|
||||||
|
winsorize(ts_delta(implied_volatility_call_120, 5), 3) |
||||||
|
|
||||||
|
normalize(ts_corr(implied_volatility_call_120, implied_volatility_put_90, 10), true) |
||||||
|
|
||||||
|
rank(add(ts_mean(implied_volatility_call_120, 5), ts_mean(implied_volatility_put_90, 5))) |
||||||
|
|
||||||
|
if_else(subtract(implied_volatility_call_120, implied_volatility_put_90) > 0, ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 0) |
||||||
|
|
||||||
|
group_neutralize(ts_zscore(subtract(implied_volatility_call_120, implied_volatility_put_90), 20), sector) |
||||||
|
|
||||||
|
ts_scale(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 20) |
||||||
|
|
||||||
|
multiply(subtract(implied_volatility_call_120, implied_volatility_put_90), power(fscore_bfl_total, 0.5)) |
||||||
|
|
||||||
|
divide(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), ts_std_dev(implied_volatility_call_120, 10)) |
||||||
|
|
||||||
|
vec_avg(bucket(subtract(implied_volatility_call_120, implied_volatility_put_90))) |
||||||
|
|
||||||
|
ts_av_diff(subtract(implied_volatility_call_120, implied_volatility_put_90), 15) |
||||||
|
|
||||||
|
sign(ts_delta(subtract(implied_volatility_call_120, implied_volatility_put_90), 3)) |
||||||
|
|
||||||
|
abs(ts_regression(implied_volatility_call_120, implied_volatility_put_90, 10, 0, 1)) |
||||||
|
|
||||||
|
hump(subtract(implied_volatility_call_120, implied_volatility_put_90), 0.02) |
||||||
|
|
||||||
|
last_diff_value(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), 5) |
||||||
|
|
||||||
|
kth_element(subtract(implied_volatility_call_120, implied_volatility_put_90), 10, 3) |
||||||
|
|
||||||
|
quantile(ts_rank(subtract(implied_volatility_call_120, implied_volatility_put_90), 10), gaussian, 1.0) |
||||||
|
|
||||||
|
group_zscore(subtract(implied_volatility_call_120, implied_volatility_put_90), industry) |
||||||
@ -0,0 +1,206 @@ |
|||||||
|
任务指令 |
||||||
|
【策略类型】优化因子 |
||||||
|
-ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756) |
||||||
|
估值偏离波动空头策略 |
||||||
|
[[假设]] |
||||||
|
价值因子与动量因子在股票中通常不相关,若某只股票同时呈现高动量与高价值评分相关性,则表明其股价与内在价值存在偏离——据此我们对这类股票建立空头仓位。 |
||||||
|
[[实施方案]] |
||||||
|
使用ts_corr()函数测算过去三年间估值评分与动量评分的相关性,通过ts_backfill()算子对前期缺失数据进行回填。 |
||||||
|
[[阿尔法因子优化建议]] |
||||||
|
建议运用分组算子与模型数据,在同类股票组内进行横向比较分析。 |
||||||
|
【数据特点】 |
||||||
|
指标数据采用EAV结构存储: |
||||||
|
- name字段:存储指标名称 |
||||||
|
- value字段:存储具体数值 |
||||||
|
- 需要通过模糊匹配name字段查找相关指标 |
||||||
|
- 需要英文字段名 |
||||||
|
【输出要求】 |
||||||
|
1. 格式:纯Python列表,不含任何其他内容 |
||||||
|
2. 内容:字段名的模糊匹配关键词,输出基础的词根, 禁止使用类似111_222_333, 只一个keyword, 我用模糊搜索就行了 |
||||||
|
3. 范围:涵盖核心指标及相关辅助指标 |
||||||
|
4. 禁止:不写完整策略代码,不写SQL,不加注释,不写示例 |
||||||
|
*=========================================================================================* |
||||||
|
输出格式: |
||||||
|
输出必须是且仅是纯文本。 |
||||||
|
每一行是一个完整、独立、语法正确的WebSim表达式。 |
||||||
|
严禁任何形式的解释、编号、标点包裹(如引号)、Markdown格式或额外文本。 |
||||||
|
===================== !!! 重点(输出方式) !!! ===================== |
||||||
|
现在,请严格遵守以上所有规则,开始生成可立即在WebSim中运行的复合因子表达式。 |
||||||
|
**输出格式**(一行一个表达式, 每个表达式中间需要添加一个空行, 只要表达式本身, 不要解释, 不需要序号, 也不要输出多余的东西): |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
... |
||||||
|
表达式 |
||||||
|
================================================================= |
||||||
|
重申:请确保所有表达式都使用WorldQuant WebSim平台函数,不要使用pandas、numpy或其他Python库函数。输出必须是一行有效的WQ表达式。 |
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 以及我提供的数据集, 进行生成,组合 10 个alpha: |
||||||
|
|
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 进行生成,组合因子 |
||||||
|
|
||||||
|
========================= 操作符开始 =======================================注意: Operator: 后面的是操作符, |
||||||
|
Description: 此字段后面的是操作符对应的描述或使用说明, Description字段后面的内容是使用说明, 不是操作符 |
||||||
|
特别注意!!!! 必须按照操作符字段Operator的使用说明生成 alphaOperator: abs(x) |
||||||
|
Description: Absolute value of x |
||||||
|
Operator: add(x, y, filter = false) |
||||||
|
Description: Add all inputs (at least 2 inputs required). If filter = true, filter all input NaN to 0 before adding |
||||||
|
Operator: densify(x) |
||||||
|
Description: Converts a grouping field of many buckets into lesser number of only available buckets so as to make working with grouping fields computationally efficient |
||||||
|
Operator: divide(x, y) |
||||||
|
Description: x / y |
||||||
|
Operator: inverse(x) |
||||||
|
Description: 1 / x |
||||||
|
Operator: log(x) |
||||||
|
Description: Natural logarithm. For example: Log(high/low) uses natural logarithm of high/low ratio as stock weights. |
||||||
|
Operator: max(x, y, ..) |
||||||
|
Description: Maximum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: min(x, y ..) |
||||||
|
Description: Minimum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: multiply(x ,y, ... , filter=false) |
||||||
|
Description: Multiply all inputs. At least 2 inputs are required. Filter sets the NaN values to 1 |
||||||
|
Operator: power(x, y) |
||||||
|
Description: x ^ y |
||||||
|
Operator: reverse(x) |
||||||
|
Description: - x |
||||||
|
Operator: sign(x) |
||||||
|
Description: if input > 0, return 1; if input < 0, return -1; if input = 0, return 0; if input = NaN, return NaN; |
||||||
|
Operator: signed_power(x, y) |
||||||
|
Description: x raised to the power of y such that final result preserves sign of x |
||||||
|
Operator: sqrt(x) |
||||||
|
Description: Square root of x |
||||||
|
Operator: subtract(x, y, filter=false) |
||||||
|
Description: x-y. If filter = true, filter all input NaN to 0 before subtracting |
||||||
|
Operator: and(input1, input2) |
||||||
|
Description: Logical AND operator, returns true if both operands are true and returns false otherwise |
||||||
|
Operator: if_else(input1, input2, input 3) |
||||||
|
Description: If input1 is true then return input2 else return input3. |
||||||
|
Operator: input1 < input2 |
||||||
|
Description: If input1 < input2 return true, else return false |
||||||
|
Operator: input1 <= input2 |
||||||
|
Description: Returns true if input1 <= input2, return false otherwise |
||||||
|
Operator: input1 == input2 |
||||||
|
Description: Returns true if both inputs are same and returns false otherwise |
||||||
|
Operator: input1 > input2 |
||||||
|
Description: Logic comparison operators to compares two inputs |
||||||
|
Operator: input1 >= input2 |
||||||
|
Description: Returns true if input1 >= input2, return false otherwise |
||||||
|
Operator: input1!= input2 |
||||||
|
Description: Returns true if both inputs are NOT the same and returns false otherwise |
||||||
|
Operator: is_nan(input) |
||||||
|
Description: If (input == NaN) return 1 else return 0 |
||||||
|
Operator: not(x) |
||||||
|
Description: Returns the logical negation of x. If x is true (1), it returns false (0), and if input is false (0), it returns true (1). |
||||||
|
Operator: or(input1, input2) |
||||||
|
Description: Logical OR operator returns true if either or both inputs are true and returns false otherwise |
||||||
|
Operator: days_from_last_change(x) |
||||||
|
Description: Amount of days since last change of x |
||||||
|
Operator: hump(x, hump = 0.01) |
||||||
|
Description: Limits amount and magnitude of changes in input (thus reducing turnover) |
||||||
|
Operator: kth_element(x, d, k) |
||||||
|
Description: Returns K-th value of input by looking through lookback days. This operator can be used to backfill missing data if k=1 |
||||||
|
Operator: last_diff_value(x, d) |
||||||
|
Description: Returns last x value not equal to current x value from last d days |
||||||
|
Operator: ts_arg_max(x, d) |
||||||
|
Description: Returns the relative index of the max value in the time series for the past d days. If the current day has the max value for the past d days, it returns 0. If previous day has the max value for the past d days, it returns 1 |
||||||
|
Operator: ts_arg_min(x, d) |
||||||
|
Description: Returns the relative index of the min value in the time series for the past d days; If the current day has the min value for the past d days, it returns 0; If previous day has the min value for the past d days, it returns 1. |
||||||
|
Operator: ts_av_diff(x, d) |
||||||
|
Description: Returns x - tsmean(x, d), but deals with NaNs carefully. That is NaNs are ignored during mean computation |
||||||
|
Operator: ts_backfill(x,lookback = d, k=1, ignore="NAN") |
||||||
|
Description: Backfill is the process of replacing the NAN or 0 values by a meaningful value (i.e., a first non-NaN value) |
||||||
|
Operator: ts_corr(x, y, d) |
||||||
|
Description: Returns correlation of x and y for the past d days |
||||||
|
Operator: ts_count_nans(x ,d) |
||||||
|
Description: Returns the number of NaN values in x for the past d days |
||||||
|
Operator: ts_covariance(y, x, d) |
||||||
|
Description: Returns covariance of y and x for the past d days |
||||||
|
Operator: ts_decay_linear(x, d, dense = false) |
||||||
|
Description: Returns the linear decay on x for the past d days. Dense parameter=false means operator works in sparse mode and we treat NaN as 0. In dense mode we do not. |
||||||
|
Operator: ts_delay(x, d) |
||||||
|
Description: Returns x value d days ago |
||||||
|
Operator: ts_delta(x, d) |
||||||
|
Description: Returns x - ts_delay(x, d) |
||||||
|
Operator: ts_mean(x, d) |
||||||
|
Description: Returns average value of x for the past d days. |
||||||
|
Operator: ts_product(x, d) |
||||||
|
Description: Returns product of x for the past d days |
||||||
|
Operator: ts_quantile(x,d, driver="gaussian" ) |
||||||
|
Description: It calculates ts_rank and apply to its value an inverse cumulative density function from driver distribution. Possible values of driver (optional ) are "gaussian", "uniform", "cauchy" distribution where "gaussian" is the default. |
||||||
|
Operator: ts_rank(x, d, constant = 0) |
||||||
|
Description: Rank the values of x for each instrument over the past d days, then return the rank of the current value + constant. If not specified, by default, constant = 0. |
||||||
|
Operator: ts_regression(y, x, d, lag = 0, rettype = 0) |
||||||
|
Description: Returns various parameters related to regression function |
||||||
|
Operator: ts_scale(x, d, constant = 0) |
||||||
|
Description: Returns (x - ts_min(x, d)) / (ts_max(x, d) - ts_min(x, d)) + constant. This operator is similar to scale down operator but acts in time series space |
||||||
|
Operator: ts_std_dev(x, d) |
||||||
|
Description: Returns standard deviation of x for the past d days |
||||||
|
Operator: ts_step(1) |
||||||
|
Description: Returns days' counter |
||||||
|
Operator: ts_sum(x, d) |
||||||
|
Description: Sum values of x for the past d days. |
||||||
|
Operator: ts_zscore(x, d) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean: (x - tsmean(x,d)) / tsstddev(x,d). This operator may help reduce outliers and drawdown. |
||||||
|
Operator: normalize(x, useStd = false, limit = 0.0) |
||||||
|
Description: Calculates the mean value of all valid alpha values for a certain date, then subtracts that mean from each element |
||||||
|
Operator: quantile(x, driver = gaussian, sigma = 1.0) |
||||||
|
Description: Rank the raw vector, shift the ranked Alpha vector, apply distribution (gaussian, cauchy, uniform). If driver is uniform, it simply subtract each Alpha value with the mean of all Alpha values in the Alpha vector |
||||||
|
Operator: rank(x, rate=2) |
||||||
|
Description: Ranks the input among all the instruments and returns an equally distributed number between 0.0 and 1.0. For precise sort, use the rate as 0 |
||||||
|
Operator: scale(x, scale=1, longscale=1, shortscale=1) |
||||||
|
Description: Scales input to booksize. We can also scale the long positions and short positions to separate scales by mentioning additional parameters to the operator |
||||||
|
Operator: winsorize(x, std=4) |
||||||
|
Description: Winsorizes x to make sure that all values in x are between the lower and upper limits, which are specified as multiple of std. |
||||||
|
Operator: zscore(x) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean |
||||||
|
Operator: vec_avg(x) |
||||||
|
Description: Taking mean of the vector field x |
||||||
|
Operator: vec_sum(x) |
||||||
|
Description: Sum of vector field x |
||||||
|
Operator: bucket(rank(x), range="0, 1, 0.1" or buckets = "2,5,6,7,10") |
||||||
|
Description: Convert float values into indexes for user-specified buckets. Bucket is useful for creating group values, which can be passed to GROUP as input |
||||||
|
Operator: trade_when(x, y, z) |
||||||
|
Description: Used in order to change Alpha values only under a specified condition and to hold Alpha values in other cases. It also allows to close Alpha positions (assign NaN values) under a specified condition |
||||||
|
Operator: group_backfill(x, group, d, std = 4.0) |
||||||
|
Description: If a certain value for a certain date and instrument is NaN, from the set of same group instruments, calculate winsorized mean of all non-NaN values over last d days |
||||||
|
Operator: group_mean(x, weight, group) |
||||||
|
Description: All elements in group equals to the mean |
||||||
|
Operator: group_neutralize(x, group) |
||||||
|
Description: Neutralizes Alpha against groups. These groups can be subindustry, industry, sector, country or a constant |
||||||
|
Operator: group_rank(x, group) |
||||||
|
Description: Each elements in a group is assigned the corresponding rank in this group |
||||||
|
Operator: group_scale(x, group) |
||||||
|
Description: Normalizes the values in a group to be between 0 and 1. (x - groupmin) / (groupmax - groupmin) |
||||||
|
Operator: group_zscore(x, group) |
||||||
|
Description: Calculates group Z-score - numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean. zscore = (data - mean) / stddev of x for each instrument within its group. |
||||||
|
========================= 操作符结束 ======================================= |
||||||
|
|
||||||
|
========================= 数据字段开始 ======================================= |
||||||
|
注意: data_set_name: 后面的是数据字段(可以使用), description: 此字段后面的是数据字段对应的描述或使用说明(不能使用), description_cn字段后面的内容是中文使用说明(不能使用) |
||||||
|
|
||||||
|
{'id': '240', 'data_set_name': 'fnd6_eventv110_gdwlieps12', 'description': 'Impairment of Goodwill Basic EPS Effect 12MM', 'description_cn': 'goodwill_impairment_basic_eps_effect_12m'} |
||||||
|
{'id': '241', 'data_set_name': 'fnd6_eventv110_gdwliepsq', 'description': 'Impairment of Goodwill Basic EPS Effect', 'description_cn': 'goodwill impairment basic_eps_effect'} |
||||||
|
{'id': '624', 'data_set_name': 'fnd6_newqeventv110_spcedq', 'description': 'S&P Core Earnings EPS Diluted', 'description_cn': 'SPCE earnings per share diluted'} |
||||||
|
{'id': '691', 'data_set_name': 'fnd6_newqv1300_cipenq', 'description': 'Comp Inc - Minimum Pension Adj', 'description_cn': '-comp_inc_min_pension_adj'} |
||||||
|
{'id': '989', 'data_set_name': 'fscore_bfl_total', 'description': 'The final score M-Score is a weighted average of both the Pentagon surface score and the Pentagon acceleration score.', 'description_cn': '最终得分M-_score=五角大楼表面评分与五角加速评分加权平均值'} |
||||||
|
{'id': '997', 'data_set_name': 'fscore_total', 'description': 'The final score M-Score is a weighted average of both the Pentagon surface score and the Pentagon acceleration score.', 'description_cn': '最终得分M-Score是pentagon表面分数和pentagon加速度分数的加权平均值。'} |
||||||
|
{'id': '1292', 'data_set_name': 'anl4_netdebt_flag', 'description': 'Net debt - forecast type (revision/new/...)', 'description_cn': '净负债-预测类型(修正值/新值/....ImageAlign\n<|im_start|>user\nstrike price'} |
||||||
|
{'id': '1927', 'data_set_name': 'news_max_up_amt', 'description': 'The after the news high minus the price at the time of the news', 'description_cn': '新闻后 highs 减去 新闻时 price 的差值'} |
||||||
|
{'id': '1931', 'data_set_name': 'news_mins_10_pct_up', 'description': 'Number of minutes that elapsed before price went up 10 percentage points', 'description_cn': '价格上升10个百分点前elapsed分钟数'} |
||||||
|
{'id': '1933', 'data_set_name': 'news_mins_1_pct_dn', 'description': 'Number of minutes that elapsed before price went down 1 percentage point', 'description_cn': '价格下跌1个百分点前elapsed分钟数'} |
||||||
|
{'id': '1934', 'data_set_name': 'news_mins_1_pct_up', 'description': 'Number of minutes that elapsed before price went up 1 percentage point', 'description_cn': '价格上升1个百分点前elapsed的分钟数'} |
||||||
|
{'id': '1942', 'data_set_name': 'news_mins_3_pct_dn', 'description': 'Number of minutes that elapsed before price went down 3 percentage points', 'description_cn': '价格下跌3个百分点前 elapsed_分钟数'} |
||||||
|
{'id': '1945', 'data_set_name': 'news_mins_4_pct_dn', 'description': 'Number of minutes that elapsed before price went down 4 percentage points', 'description_cn': '价格下跌4个百分点前elapsed分钟数'} |
||||||
|
{'id': '1946', 'data_set_name': 'news_mins_4_pct_up', 'description': 'Number of minutes that elapsed before price went up 4 percentage points', 'description_cn': '价格上漲4個百分點前 elapsed 分钟数'} |
||||||
|
{'id': '1985', 'data_set_name': 'nws12_afterhsz_01s', 'description': 'Number of minutes that elapsed before price went down 10 percentage points', 'description_cn': '价格下跌至低于初始水平10个百分点前elapsed分钟数'} |
||||||
|
{'id': '1992', 'data_set_name': 'nws12_afterhsz_1l', 'description': 'Number of minutes that elapsed before price went up 1 percentage points', 'description_cn': '涨价至1个百分点前elapsed分钟数'} |
||||||
|
{'id': '1999', 'data_set_name': 'nws12_afterhsz_3l', 'description': 'Number of minutes that elapsed before price went up 3 percentage points', 'description_cn': '价格上涨3个百分点前elapsed的分钟数'} |
||||||
|
{'id': '2001', 'data_set_name': 'nws12_afterhsz_3s', 'description': 'Number of minutes that elapsed before price went down 3 percentage points', 'description_cn': '价格下跌3个百分点前elapsed分钟数'} |
||||||
|
{'id': '2003', 'data_set_name': 'nws12_afterhsz_4l', 'description': 'Number of minutes that elapsed before price went up 4 percentage points', 'description_cn': '价格上升4个百分点前elapsed分钟数'} |
||||||
|
{'id': '2089', 'data_set_name': 'nws12_mainz_4l', 'description': 'Number of minutes that elapsed before price went up 4 percentage points', 'description_cn': '价格上涨4个百分点前elapsed分钟数'} |
||||||
|
{'id': '2154', 'data_set_name': 'nws12_prez_02s', 'description': 'Number of minutes that elapsed before price went down 20 percentage points', 'description_cn': '价格下跌20个百分点前elapsed分钟数'} |
||||||
|
{'id': '2168', 'data_set_name': 'nws12_prez_3s', 'description': 'Number of minutes that elapsed before price went down 3 percentage points', 'description_cn': '价格下跌3个百分点前elapsed分钟数'} |
||||||
|
{'id': '2172', 'data_set_name': 'nws12_prez_4s', 'description': 'Number of minutes that elapsed before price went down 4 percentage points', 'description_cn': '价格下跌4个百分点前elapsed分钟数'} |
||||||
|
{'id': '2173', 'data_set_name': 'nws12_prez_57l', 'description': 'Number of minutes that elapsed before price went up 7.5 percentage points', 'description_cn': '价格上升7.5个百分点前elapsed分钟数'} |
||||||
|
{'id': '2179', 'data_set_name': 'nws12_prez_5s', 'description': 'Number of minutes that elapsed before price went down 5 percentage points', 'description_cn': '价格下跌5个百分点前elapsed分钟数'} |
||||||
|
========================= 数据字段结束 ======================================= |
||||||
|
|
||||||
@ -0,0 +1,206 @@ |
|||||||
|
任务指令 |
||||||
|
【策略类型】优化因子 |
||||||
|
-ts_corr(ts_backfill(fscore_momentum,66),ts_backfill(fscore_value,66),756) |
||||||
|
估值偏离波动空头策略 |
||||||
|
[[假设]] |
||||||
|
价值因子与动量因子在股票中通常不相关,若某只股票同时呈现高动量与高价值评分相关性,则表明其股价与内在价值存在偏离——据此我们对这类股票建立空头仓位。 |
||||||
|
[[实施方案]] |
||||||
|
使用ts_corr()函数测算过去三年间估值评分与动量评分的相关性,通过ts_backfill()算子对前期缺失数据进行回填。 |
||||||
|
[[阿尔法因子优化建议]] |
||||||
|
建议运用分组算子与模型数据,在同类股票组内进行横向比较分析。 |
||||||
|
【数据特点】 |
||||||
|
指标数据采用EAV结构存储: |
||||||
|
- name字段:存储指标名称 |
||||||
|
- value字段:存储具体数值 |
||||||
|
- 需要通过模糊匹配name字段查找相关指标 |
||||||
|
- 需要英文字段名 |
||||||
|
【输出要求】 |
||||||
|
1. 格式:纯Python列表,不含任何其他内容 |
||||||
|
2. 内容:字段名的模糊匹配关键词,输出基础的词根, 禁止使用类似111_222_333, 只一个keyword, 我用模糊搜索就行了 |
||||||
|
3. 范围:涵盖核心指标及相关辅助指标 |
||||||
|
4. 禁止:不写完整策略代码,不写SQL,不加注释,不写示例 |
||||||
|
*=========================================================================================* |
||||||
|
输出格式: |
||||||
|
输出必须是且仅是纯文本。 |
||||||
|
每一行是一个完整、独立、语法正确的WebSim表达式。 |
||||||
|
严禁任何形式的解释、编号、标点包裹(如引号)、Markdown格式或额外文本。 |
||||||
|
===================== !!! 重点(输出方式) !!! ===================== |
||||||
|
现在,请严格遵守以上所有规则,开始生成可立即在WebSim中运行的复合因子表达式。 |
||||||
|
**输出格式**(一行一个表达式, 每个表达式中间需要添加一个空行, 只要表达式本身, 不要解释, 不需要序号, 也不要输出多余的东西): |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
... |
||||||
|
表达式 |
||||||
|
================================================================= |
||||||
|
重申:请确保所有表达式都使用WorldQuant WebSim平台函数,不要使用pandas、numpy或其他Python库函数。输出必须是一行有效的WQ表达式。 |
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 以及我提供的数据集, 进行生成,组合 20 个alpha: |
||||||
|
|
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 进行生成,组合因子 |
||||||
|
|
||||||
|
========================= 操作符开始 =======================================注意: Operator: 后面的是操作符, |
||||||
|
Description: 此字段后面的是操作符对应的描述或使用说明, Description字段后面的内容是使用说明, 不是操作符 |
||||||
|
特别注意!!!! 必须按照操作符字段Operator的使用说明生成 alphaOperator: abs(x) |
||||||
|
Description: Absolute value of x |
||||||
|
Operator: add(x, y, filter = false) |
||||||
|
Description: Add all inputs (at least 2 inputs required). If filter = true, filter all input NaN to 0 before adding |
||||||
|
Operator: densify(x) |
||||||
|
Description: Converts a grouping field of many buckets into lesser number of only available buckets so as to make working with grouping fields computationally efficient |
||||||
|
Operator: divide(x, y) |
||||||
|
Description: x / y |
||||||
|
Operator: inverse(x) |
||||||
|
Description: 1 / x |
||||||
|
Operator: log(x) |
||||||
|
Description: Natural logarithm. For example: Log(high/low) uses natural logarithm of high/low ratio as stock weights. |
||||||
|
Operator: max(x, y, ..) |
||||||
|
Description: Maximum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: min(x, y ..) |
||||||
|
Description: Minimum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: multiply(x ,y, ... , filter=false) |
||||||
|
Description: Multiply all inputs. At least 2 inputs are required. Filter sets the NaN values to 1 |
||||||
|
Operator: power(x, y) |
||||||
|
Description: x ^ y |
||||||
|
Operator: reverse(x) |
||||||
|
Description: - x |
||||||
|
Operator: sign(x) |
||||||
|
Description: if input > 0, return 1; if input < 0, return -1; if input = 0, return 0; if input = NaN, return NaN; |
||||||
|
Operator: signed_power(x, y) |
||||||
|
Description: x raised to the power of y such that final result preserves sign of x |
||||||
|
Operator: sqrt(x) |
||||||
|
Description: Square root of x |
||||||
|
Operator: subtract(x, y, filter=false) |
||||||
|
Description: x-y. If filter = true, filter all input NaN to 0 before subtracting |
||||||
|
Operator: and(input1, input2) |
||||||
|
Description: Logical AND operator, returns true if both operands are true and returns false otherwise |
||||||
|
Operator: if_else(input1, input2, input 3) |
||||||
|
Description: If input1 is true then return input2 else return input3. |
||||||
|
Operator: input1 < input2 |
||||||
|
Description: If input1 < input2 return true, else return false |
||||||
|
Operator: input1 <= input2 |
||||||
|
Description: Returns true if input1 <= input2, return false otherwise |
||||||
|
Operator: input1 == input2 |
||||||
|
Description: Returns true if both inputs are same and returns false otherwise |
||||||
|
Operator: input1 > input2 |
||||||
|
Description: Logic comparison operators to compares two inputs |
||||||
|
Operator: input1 >= input2 |
||||||
|
Description: Returns true if input1 >= input2, return false otherwise |
||||||
|
Operator: input1!= input2 |
||||||
|
Description: Returns true if both inputs are NOT the same and returns false otherwise |
||||||
|
Operator: is_nan(input) |
||||||
|
Description: If (input == NaN) return 1 else return 0 |
||||||
|
Operator: not(x) |
||||||
|
Description: Returns the logical negation of x. If x is true (1), it returns false (0), and if input is false (0), it returns true (1). |
||||||
|
Operator: or(input1, input2) |
||||||
|
Description: Logical OR operator returns true if either or both inputs are true and returns false otherwise |
||||||
|
Operator: days_from_last_change(x) |
||||||
|
Description: Amount of days since last change of x |
||||||
|
Operator: hump(x, hump = 0.01) |
||||||
|
Description: Limits amount and magnitude of changes in input (thus reducing turnover) |
||||||
|
Operator: kth_element(x, d, k) |
||||||
|
Description: Returns K-th value of input by looking through lookback days. This operator can be used to backfill missing data if k=1 |
||||||
|
Operator: last_diff_value(x, d) |
||||||
|
Description: Returns last x value not equal to current x value from last d days |
||||||
|
Operator: ts_arg_max(x, d) |
||||||
|
Description: Returns the relative index of the max value in the time series for the past d days. If the current day has the max value for the past d days, it returns 0. If previous day has the max value for the past d days, it returns 1 |
||||||
|
Operator: ts_arg_min(x, d) |
||||||
|
Description: Returns the relative index of the min value in the time series for the past d days; If the current day has the min value for the past d days, it returns 0; If previous day has the min value for the past d days, it returns 1. |
||||||
|
Operator: ts_av_diff(x, d) |
||||||
|
Description: Returns x - tsmean(x, d), but deals with NaNs carefully. That is NaNs are ignored during mean computation |
||||||
|
Operator: ts_backfill(x,lookback = d, k=1, ignore="NAN") |
||||||
|
Description: Backfill is the process of replacing the NAN or 0 values by a meaningful value (i.e., a first non-NaN value) |
||||||
|
Operator: ts_corr(x, y, d) |
||||||
|
Description: Returns correlation of x and y for the past d days |
||||||
|
Operator: ts_count_nans(x ,d) |
||||||
|
Description: Returns the number of NaN values in x for the past d days |
||||||
|
Operator: ts_covariance(y, x, d) |
||||||
|
Description: Returns covariance of y and x for the past d days |
||||||
|
Operator: ts_decay_linear(x, d, dense = false) |
||||||
|
Description: Returns the linear decay on x for the past d days. Dense parameter=false means operator works in sparse mode and we treat NaN as 0. In dense mode we do not. |
||||||
|
Operator: ts_delay(x, d) |
||||||
|
Description: Returns x value d days ago |
||||||
|
Operator: ts_delta(x, d) |
||||||
|
Description: Returns x - ts_delay(x, d) |
||||||
|
Operator: ts_mean(x, d) |
||||||
|
Description: Returns average value of x for the past d days. |
||||||
|
Operator: ts_product(x, d) |
||||||
|
Description: Returns product of x for the past d days |
||||||
|
Operator: ts_quantile(x,d, driver="gaussian" ) |
||||||
|
Description: It calculates ts_rank and apply to its value an inverse cumulative density function from driver distribution. Possible values of driver (optional ) are "gaussian", "uniform", "cauchy" distribution where "gaussian" is the default. |
||||||
|
Operator: ts_rank(x, d, constant = 0) |
||||||
|
Description: Rank the values of x for each instrument over the past d days, then return the rank of the current value + constant. If not specified, by default, constant = 0. |
||||||
|
Operator: ts_regression(y, x, d, lag = 0, rettype = 0) |
||||||
|
Description: Returns various parameters related to regression function |
||||||
|
Operator: ts_scale(x, d, constant = 0) |
||||||
|
Description: Returns (x - ts_min(x, d)) / (ts_max(x, d) - ts_min(x, d)) + constant. This operator is similar to scale down operator but acts in time series space |
||||||
|
Operator: ts_std_dev(x, d) |
||||||
|
Description: Returns standard deviation of x for the past d days |
||||||
|
Operator: ts_step(1) |
||||||
|
Description: Returns days' counter |
||||||
|
Operator: ts_sum(x, d) |
||||||
|
Description: Sum values of x for the past d days. |
||||||
|
Operator: ts_zscore(x, d) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean: (x - tsmean(x,d)) / tsstddev(x,d). This operator may help reduce outliers and drawdown. |
||||||
|
Operator: normalize(x, useStd = false, limit = 0.0) |
||||||
|
Description: Calculates the mean value of all valid alpha values for a certain date, then subtracts that mean from each element |
||||||
|
Operator: quantile(x, driver = gaussian, sigma = 1.0) |
||||||
|
Description: Rank the raw vector, shift the ranked Alpha vector, apply distribution (gaussian, cauchy, uniform). If driver is uniform, it simply subtract each Alpha value with the mean of all Alpha values in the Alpha vector |
||||||
|
Operator: rank(x, rate=2) |
||||||
|
Description: Ranks the input among all the instruments and returns an equally distributed number between 0.0 and 1.0. For precise sort, use the rate as 0 |
||||||
|
Operator: scale(x, scale=1, longscale=1, shortscale=1) |
||||||
|
Description: Scales input to booksize. We can also scale the long positions and short positions to separate scales by mentioning additional parameters to the operator |
||||||
|
Operator: winsorize(x, std=4) |
||||||
|
Description: Winsorizes x to make sure that all values in x are between the lower and upper limits, which are specified as multiple of std. |
||||||
|
Operator: zscore(x) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean |
||||||
|
Operator: vec_avg(x) |
||||||
|
Description: Taking mean of the vector field x |
||||||
|
Operator: vec_sum(x) |
||||||
|
Description: Sum of vector field x |
||||||
|
Operator: bucket(rank(x), range="0, 1, 0.1" or buckets = "2,5,6,7,10") |
||||||
|
Description: Convert float values into indexes for user-specified buckets. Bucket is useful for creating group values, which can be passed to GROUP as input |
||||||
|
Operator: trade_when(x, y, z) |
||||||
|
Description: Used in order to change Alpha values only under a specified condition and to hold Alpha values in other cases. It also allows to close Alpha positions (assign NaN values) under a specified condition |
||||||
|
Operator: group_backfill(x, group, d, std = 4.0) |
||||||
|
Description: If a certain value for a certain date and instrument is NaN, from the set of same group instruments, calculate winsorized mean of all non-NaN values over last d days |
||||||
|
Operator: group_mean(x, weight, group) |
||||||
|
Description: All elements in group equals to the mean |
||||||
|
Operator: group_neutralize(x, group) |
||||||
|
Description: Neutralizes Alpha against groups. These groups can be subindustry, industry, sector, country or a constant |
||||||
|
Operator: group_rank(x, group) |
||||||
|
Description: Each elements in a group is assigned the corresponding rank in this group |
||||||
|
Operator: group_scale(x, group) |
||||||
|
Description: Normalizes the values in a group to be between 0 and 1. (x - groupmin) / (groupmax - groupmin) |
||||||
|
Operator: group_zscore(x, group) |
||||||
|
Description: Calculates group Z-score - numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean. zscore = (data - mean) / stddev of x for each instrument within its group. |
||||||
|
========================= 操作符结束 ======================================= |
||||||
|
|
||||||
|
========================= 数据字段开始 ======================================= |
||||||
|
注意: data_set_name: 后面的是数据字段(可以使用), description: 此字段后面的是数据字段对应的描述或使用说明(不能使用), description_cn字段后面的内容是中文使用说明(不能使用) |
||||||
|
|
||||||
|
{'id': '240', 'data_set_name': 'fnd6_eventv110_gdwlieps12', 'description': 'Impairment of Goodwill Basic EPS Effect 12MM', 'description_cn': 'goodwill_impairment_basic_eps_effect_12m'} |
||||||
|
{'id': '241', 'data_set_name': 'fnd6_eventv110_gdwliepsq', 'description': 'Impairment of Goodwill Basic EPS Effect', 'description_cn': 'goodwill impairment basic_eps_effect'} |
||||||
|
{'id': '624', 'data_set_name': 'fnd6_newqeventv110_spcedq', 'description': 'S&P Core Earnings EPS Diluted', 'description_cn': 'SPCE earnings per share diluted'} |
||||||
|
{'id': '691', 'data_set_name': 'fnd6_newqv1300_cipenq', 'description': 'Comp Inc - Minimum Pension Adj', 'description_cn': '-comp_inc_min_pension_adj'} |
||||||
|
{'id': '989', 'data_set_name': 'fscore_bfl_total', 'description': 'The final score M-Score is a weighted average of both the Pentagon surface score and the Pentagon acceleration score.', 'description_cn': '最终得分M-_score=五角大楼表面评分与五角加速评分加权平均值'} |
||||||
|
{'id': '997', 'data_set_name': 'fscore_total', 'description': 'The final score M-Score is a weighted average of both the Pentagon surface score and the Pentagon acceleration score.', 'description_cn': '最终得分M-Score是pentagon表面分数和pentagon加速度分数的加权平均值。'} |
||||||
|
{'id': '1292', 'data_set_name': 'anl4_netdebt_flag', 'description': 'Net debt - forecast type (revision/new/...)', 'description_cn': '净负债-预测类型(修正值/新值/....ImageAlign\n<|im_start|>user\nstrike price'} |
||||||
|
{'id': '1927', 'data_set_name': 'news_max_up_amt', 'description': 'The after the news high minus the price at the time of the news', 'description_cn': '新闻后 highs 减去 新闻时 price 的差值'} |
||||||
|
{'id': '1931', 'data_set_name': 'news_mins_10_pct_up', 'description': 'Number of minutes that elapsed before price went up 10 percentage points', 'description_cn': '价格上升10个百分点前elapsed分钟数'} |
||||||
|
{'id': '1933', 'data_set_name': 'news_mins_1_pct_dn', 'description': 'Number of minutes that elapsed before price went down 1 percentage point', 'description_cn': '价格下跌1个百分点前elapsed分钟数'} |
||||||
|
{'id': '1934', 'data_set_name': 'news_mins_1_pct_up', 'description': 'Number of minutes that elapsed before price went up 1 percentage point', 'description_cn': '价格上升1个百分点前elapsed的分钟数'} |
||||||
|
{'id': '1942', 'data_set_name': 'news_mins_3_pct_dn', 'description': 'Number of minutes that elapsed before price went down 3 percentage points', 'description_cn': '价格下跌3个百分点前 elapsed_分钟数'} |
||||||
|
{'id': '1945', 'data_set_name': 'news_mins_4_pct_dn', 'description': 'Number of minutes that elapsed before price went down 4 percentage points', 'description_cn': '价格下跌4个百分点前elapsed分钟数'} |
||||||
|
{'id': '1946', 'data_set_name': 'news_mins_4_pct_up', 'description': 'Number of minutes that elapsed before price went up 4 percentage points', 'description_cn': '价格上漲4個百分點前 elapsed 分钟数'} |
||||||
|
{'id': '1985', 'data_set_name': 'nws12_afterhsz_01s', 'description': 'Number of minutes that elapsed before price went down 10 percentage points', 'description_cn': '价格下跌至低于初始水平10个百分点前elapsed分钟数'} |
||||||
|
{'id': '1992', 'data_set_name': 'nws12_afterhsz_1l', 'description': 'Number of minutes that elapsed before price went up 1 percentage points', 'description_cn': '涨价至1个百分点前elapsed分钟数'} |
||||||
|
{'id': '1999', 'data_set_name': 'nws12_afterhsz_3l', 'description': 'Number of minutes that elapsed before price went up 3 percentage points', 'description_cn': '价格上涨3个百分点前elapsed的分钟数'} |
||||||
|
{'id': '2001', 'data_set_name': 'nws12_afterhsz_3s', 'description': 'Number of minutes that elapsed before price went down 3 percentage points', 'description_cn': '价格下跌3个百分点前elapsed分钟数'} |
||||||
|
{'id': '2003', 'data_set_name': 'nws12_afterhsz_4l', 'description': 'Number of minutes that elapsed before price went up 4 percentage points', 'description_cn': '价格上升4个百分点前elapsed分钟数'} |
||||||
|
{'id': '2089', 'data_set_name': 'nws12_mainz_4l', 'description': 'Number of minutes that elapsed before price went up 4 percentage points', 'description_cn': '价格上涨4个百分点前elapsed分钟数'} |
||||||
|
{'id': '2154', 'data_set_name': 'nws12_prez_02s', 'description': 'Number of minutes that elapsed before price went down 20 percentage points', 'description_cn': '价格下跌20个百分点前elapsed分钟数'} |
||||||
|
{'id': '2168', 'data_set_name': 'nws12_prez_3s', 'description': 'Number of minutes that elapsed before price went down 3 percentage points', 'description_cn': '价格下跌3个百分点前elapsed分钟数'} |
||||||
|
{'id': '2172', 'data_set_name': 'nws12_prez_4s', 'description': 'Number of minutes that elapsed before price went down 4 percentage points', 'description_cn': '价格下跌4个百分点前elapsed分钟数'} |
||||||
|
{'id': '2173', 'data_set_name': 'nws12_prez_57l', 'description': 'Number of minutes that elapsed before price went up 7.5 percentage points', 'description_cn': '价格上升7.5个百分点前elapsed分钟数'} |
||||||
|
{'id': '2179', 'data_set_name': 'nws12_prez_5s', 'description': 'Number of minutes that elapsed before price went down 5 percentage points', 'description_cn': '价格下跌5个百分点前elapsed分钟数'} |
||||||
|
========================= 数据字段结束 ======================================= |
||||||
|
|
||||||
@ -0,0 +1,182 @@ |
|||||||
|
任务指令 |
||||||
|
需优化因子: scale(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10)) |
||||||
|
金融逻辑:该策略通过追踪期权市场上虚值看涨与看跌波动率的持续差值,捕捉市场对某只股票极端上涨的强烈且持续的投机情绪或对冲需求,并预期这种情绪会通过做市商的被动对冲行为或信息传递,最终转化为股价的实际动能。 |
||||||
|
核心假设:策略假设期权市场隐含了现货价格尚未反映的前瞻性情绪,且这种情绪具有持续性,更重要的是,做市商为对冲期权头寸而进行的现货买卖操作,会系统性推动价格向情绪预期的方向移动。 |
||||||
|
实施方案:每日计算各股票深度虚值看涨与看跌期权隐含波动率之差,并累加过去一段时间的差值形成动量信号,最后对整个股票池的该信号进行横截面标准化,据此构建多空组合进行交易。 |
||||||
|
优化建议:可以通过用平值波动率对差值进行标准化来剔除市场整体恐慌影响,并结合期权成交量进行过滤以排除流动性噪音,同时严格避开财报发布和期权到期等已知的波动率扭曲事件,以提升信号的纯净度和稳健性。 |
||||||
|
|
||||||
|
*=========================================================================================* |
||||||
|
输出格式: |
||||||
|
输出必须是且仅是纯文本。 |
||||||
|
每一行是一个完整、独立、语法正确的WebSim表达式。 |
||||||
|
严禁任何形式的解释、编号、标点包裹(如引号)、Markdown格式或额外文本。 |
||||||
|
===================== !!! 重点(输出方式) !!! ===================== |
||||||
|
现在,请严格遵守以上所有规则,开始生成可立即在WebSim中运行的复合因子表达式。 |
||||||
|
**输出格式**(一行一个表达式, 每个表达式中间需要添加一个空行, 只要表达式本身, 不要解释, 不需要序号, 也不要输出多余的东西): |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
... |
||||||
|
表达式 |
||||||
|
================================================================= |
||||||
|
重申:请确保所有表达式都使用WorldQuant WebSim平台函数,不要使用pandas、numpy或其他Python库函数。输出必须是一行有效的WQ表达式。 |
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 以及我提供的数据集, 进行生成,组合 20 个alpha: |
||||||
|
|
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 进行生成,组合因子 |
||||||
|
|
||||||
|
========================= 操作符开始 =======================================注意: Operator: 后面的是操作符, |
||||||
|
Description: 此字段后面的是操作符对应的描述或使用说明, Description字段后面的内容是使用说明, 不是操作符 |
||||||
|
特别注意!!!! 必须按照操作符字段Operator的使用说明生成 alphaOperator: abs(x) |
||||||
|
Description: Absolute value of x |
||||||
|
Operator: add(x, y, filter = false) |
||||||
|
Description: Add all inputs (at least 2 inputs required). If filter = true, filter all input NaN to 0 before adding |
||||||
|
Operator: densify(x) |
||||||
|
Description: Converts a grouping field of many buckets into lesser number of only available buckets so as to make working with grouping fields computationally efficient |
||||||
|
Operator: divide(x, y) |
||||||
|
Description: x / y |
||||||
|
Operator: inverse(x) |
||||||
|
Description: 1 / x |
||||||
|
Operator: log(x) |
||||||
|
Description: Natural logarithm. For example: Log(high/low) uses natural logarithm of high/low ratio as stock weights. |
||||||
|
Operator: max(x, y, ..) |
||||||
|
Description: Maximum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: min(x, y ..) |
||||||
|
Description: Minimum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: multiply(x ,y, ... , filter=false) |
||||||
|
Description: Multiply all inputs. At least 2 inputs are required. Filter sets the NaN values to 1 |
||||||
|
Operator: power(x, y) |
||||||
|
Description: x ^ y |
||||||
|
Operator: reverse(x) |
||||||
|
Description: - x |
||||||
|
Operator: sign(x) |
||||||
|
Description: if input > 0, return 1; if input < 0, return -1; if input = 0, return 0; if input = NaN, return NaN; |
||||||
|
Operator: signed_power(x, y) |
||||||
|
Description: x raised to the power of y such that final result preserves sign of x |
||||||
|
Operator: sqrt(x) |
||||||
|
Description: Square root of x |
||||||
|
Operator: subtract(x, y, filter=false) |
||||||
|
Description: x-y. If filter = true, filter all input NaN to 0 before subtracting |
||||||
|
Operator: and(input1, input2) |
||||||
|
Description: Logical AND operator, returns true if both operands are true and returns false otherwise |
||||||
|
Operator: if_else(input1, input2, input 3) |
||||||
|
Description: If input1 is true then return input2 else return input3. |
||||||
|
Operator: input1 < input2 |
||||||
|
Description: If input1 < input2 return true, else return false |
||||||
|
Operator: input1 <= input2 |
||||||
|
Description: Returns true if input1 <= input2, return false otherwise |
||||||
|
Operator: input1 == input2 |
||||||
|
Description: Returns true if both inputs are same and returns false otherwise |
||||||
|
Operator: input1 > input2 |
||||||
|
Description: Logic comparison operators to compares two inputs |
||||||
|
Operator: input1 >= input2 |
||||||
|
Description: Returns true if input1 >= input2, return false otherwise |
||||||
|
Operator: input1!= input2 |
||||||
|
Description: Returns true if both inputs are NOT the same and returns false otherwise |
||||||
|
Operator: is_nan(input) |
||||||
|
Description: If (input == NaN) return 1 else return 0 |
||||||
|
Operator: not(x) |
||||||
|
Description: Returns the logical negation of x. If x is true (1), it returns false (0), and if input is false (0), it returns true (1). |
||||||
|
Operator: or(input1, input2) |
||||||
|
Description: Logical OR operator returns true if either or both inputs are true and returns false otherwise |
||||||
|
Operator: days_from_last_change(x) |
||||||
|
Description: Amount of days since last change of x |
||||||
|
Operator: hump(x, hump = 0.01) |
||||||
|
Description: Limits amount and magnitude of changes in input (thus reducing turnover) |
||||||
|
Operator: kth_element(x, d, k) |
||||||
|
Description: Returns K-th value of input by looking through lookback days. This operator can be used to backfill missing data if k=1 |
||||||
|
Operator: last_diff_value(x, d) |
||||||
|
Description: Returns last x value not equal to current x value from last d days |
||||||
|
Operator: ts_arg_max(x, d) |
||||||
|
Description: Returns the relative index of the max value in the time series for the past d days. If the current day has the max value for the past d days, it returns 0. If previous day has the max value for the past d days, it returns 1 |
||||||
|
Operator: ts_arg_min(x, d) |
||||||
|
Description: Returns the relative index of the min value in the time series for the past d days; If the current day has the min value for the past d days, it returns 0; If previous day has the min value for the past d days, it returns 1. |
||||||
|
Operator: ts_av_diff(x, d) |
||||||
|
Description: Returns x - tsmean(x, d), but deals with NaNs carefully. That is NaNs are ignored during mean computation |
||||||
|
Operator: ts_backfill(x,lookback = d, k=1, ignore="NAN") |
||||||
|
Description: Backfill is the process of replacing the NAN or 0 values by a meaningful value (i.e., a first non-NaN value) |
||||||
|
Operator: ts_corr(x, y, d) |
||||||
|
Description: Returns correlation of x and y for the past d days |
||||||
|
Operator: ts_count_nans(x ,d) |
||||||
|
Description: Returns the number of NaN values in x for the past d days |
||||||
|
Operator: ts_covariance(y, x, d) |
||||||
|
Description: Returns covariance of y and x for the past d days |
||||||
|
Operator: ts_decay_linear(x, d, dense = false) |
||||||
|
Description: Returns the linear decay on x for the past d days. Dense parameter=false means operator works in sparse mode and we treat NaN as 0. In dense mode we do not. |
||||||
|
Operator: ts_delay(x, d) |
||||||
|
Description: Returns x value d days ago |
||||||
|
Operator: ts_delta(x, d) |
||||||
|
Description: Returns x - ts_delay(x, d) |
||||||
|
Operator: ts_mean(x, d) |
||||||
|
Description: Returns average value of x for the past d days. |
||||||
|
Operator: ts_product(x, d) |
||||||
|
Description: Returns product of x for the past d days |
||||||
|
Operator: ts_quantile(x,d, driver="gaussian" ) |
||||||
|
Description: It calculates ts_rank and apply to its value an inverse cumulative density function from driver distribution. Possible values of driver (optional ) are "gaussian", "uniform", "cauchy" distribution where "gaussian" is the default. |
||||||
|
Operator: ts_rank(x, d, constant = 0) |
||||||
|
Description: Rank the values of x for each instrument over the past d days, then return the rank of the current value + constant. If not specified, by default, constant = 0. |
||||||
|
Operator: ts_regression(y, x, d, lag = 0, rettype = 0) |
||||||
|
Description: Returns various parameters related to regression function |
||||||
|
Operator: ts_scale(x, d, constant = 0) |
||||||
|
Description: Returns (x - ts_min(x, d)) / (ts_max(x, d) - ts_min(x, d)) + constant. This operator is similar to scale down operator but acts in time series space |
||||||
|
Operator: ts_std_dev(x, d) |
||||||
|
Description: Returns standard deviation of x for the past d days |
||||||
|
Operator: ts_step(1) |
||||||
|
Description: Returns days' counter |
||||||
|
Operator: ts_sum(x, d) |
||||||
|
Description: Sum values of x for the past d days. |
||||||
|
Operator: ts_zscore(x, d) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean: (x - tsmean(x,d)) / tsstddev(x,d). This operator may help reduce outliers and drawdown. |
||||||
|
Operator: normalize(x, useStd = false, limit = 0.0) |
||||||
|
Description: Calculates the mean value of all valid alpha values for a certain date, then subtracts that mean from each element |
||||||
|
Operator: quantile(x, driver = gaussian, sigma = 1.0) |
||||||
|
Description: Rank the raw vector, shift the ranked Alpha vector, apply distribution (gaussian, cauchy, uniform). If driver is uniform, it simply subtract each Alpha value with the mean of all Alpha values in the Alpha vector |
||||||
|
Operator: rank(x, rate=2) |
||||||
|
Description: Ranks the input among all the instruments and returns an equally distributed number between 0.0 and 1.0. For precise sort, use the rate as 0 |
||||||
|
Operator: scale(x, scale=1, longscale=1, shortscale=1) |
||||||
|
Description: Scales input to booksize. We can also scale the long positions and short positions to separate scales by mentioning additional parameters to the operator |
||||||
|
Operator: winsorize(x, std=4) |
||||||
|
Description: Winsorizes x to make sure that all values in x are between the lower and upper limits, which are specified as multiple of std. |
||||||
|
Operator: zscore(x) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean |
||||||
|
Operator: vec_avg(x) |
||||||
|
Description: Taking mean of the vector field x |
||||||
|
Operator: vec_sum(x) |
||||||
|
Description: Sum of vector field x |
||||||
|
Operator: bucket(rank(x), range="0, 1, 0.1" or buckets = "2,5,6,7,10") |
||||||
|
Description: Convert float values into indexes for user-specified buckets. Bucket is useful for creating group values, which can be passed to GROUP as input |
||||||
|
Operator: trade_when(x, y, z) |
||||||
|
Description: Used in order to change Alpha values only under a specified condition and to hold Alpha values in other cases. It also allows to close Alpha positions (assign NaN values) under a specified condition |
||||||
|
Operator: group_backfill(x, group, d, std = 4.0) |
||||||
|
Description: If a certain value for a certain date and instrument is NaN, from the set of same group instruments, calculate winsorized mean of all non-NaN values over last d days |
||||||
|
Operator: group_mean(x, weight, group) |
||||||
|
Description: All elements in group equals to the mean |
||||||
|
Operator: group_neutralize(x, group) |
||||||
|
Description: Neutralizes Alpha against groups. These groups can be subindustry, industry, sector, country or a constant |
||||||
|
Operator: group_rank(x, group) |
||||||
|
Description: Each elements in a group is assigned the corresponding rank in this group |
||||||
|
Operator: group_scale(x, group) |
||||||
|
Description: Normalizes the values in a group to be between 0 and 1. (x - groupmin) / (groupmax - groupmin) |
||||||
|
Operator: group_zscore(x, group) |
||||||
|
Description: Calculates group Z-score - numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean. zscore = (data - mean) / stddev of x for each instrument within its group. |
||||||
|
========================= 操作符结束 ======================================= |
||||||
|
|
||||||
|
========================= 数据字段开始 ======================================= |
||||||
|
注意: data_set_name: 后面的是数据字段(可以使用), description: 此字段后面的是数据字段对应的描述或使用说明(不能使用), description_cn字段后面的内容是中文使用说明(不能使用) |
||||||
|
|
||||||
|
{'id': '517', 'data_set_name': 'fnd6_newqeventv110_glceaq', 'description': 'Gain/Loss on Sale (Core Earnings Adjusted) After-tax', 'description_cn': '税后核心 earnings 润亏'} |
||||||
|
{'id': '624', 'data_set_name': 'fnd6_newqeventv110_spcedq', 'description': 'S&P Core Earnings EPS Diluted', 'description_cn': 'SPCE earnings per share diluted'} |
||||||
|
{'id': '625', 'data_set_name': 'fnd6_newqeventv110_spceeps12', 'description': 'S&P Core Earnings EPS Basic 12MM', 'description_cn': '标普核心 earnings 每股基本值_12M'} |
||||||
|
{'id': '628', 'data_set_name': 'fnd6_newqeventv110_spceepsq', 'description': 'S&P Core Earnings EPS Basic', 'description_cn': '标普核心 earnings 每股基本值'} |
||||||
|
{'id': '629', 'data_set_name': 'fnd6_newqeventv110_spcep12', 'description': 'S&P Core Earnings 12MM - Preliminary', 'description_cn': '标普核心 earnings 12个月 - 预liminary'} |
||||||
|
{'id': '630', 'data_set_name': 'fnd6_newqeventv110_spcepd12', 'description': 'S&P Core Earnings 12MM EPS Diluted - Preliminary', 'description_cn': 'S&P核心 earnings_12个月稀释后每股盈亏平衡点_初步'} |
||||||
|
{'id': '774', 'data_set_name': 'fnd6_newqv1300_spcedq', 'description': 'S&P Core Earnings EPS Diluted', 'description_cn': '标准普尔核心 earnings 每股稀释后利润'} |
||||||
|
{'id': '777', 'data_set_name': 'fnd6_newqv1300_spceepsq', 'description': 'S&P Core Earnings EPS Basic', 'description_cn': '标普核心 earnings EPS 基本'} |
||||||
|
{'id': '872', 'data_set_name': 'fnd6_spce', 'description': 'S&P Core Earnings', 'description_cn': '标准普尔核心 earnings'} |
||||||
|
{'id': '1292', 'data_set_name': 'anl4_netdebt_flag', 'description': 'Net debt - forecast type (revision/new/...)', 'description_cn': '净负债-预测类型(修正值/新值/....ImageAlign\n<|im_start|>user\nstrike price'} |
||||||
|
{'id': '1861', 'data_set_name': 'implied_volatility_call_60', 'description': 'At-the-money option-implied volatility for call Option for 60 days', 'description_cn': '看涨期权60天 atm 隐含波动率'} |
||||||
|
{'id': '1894', 'data_set_name': 'implied_volatility_put_270', 'description': 'At-the-money option-implied volatility for Put Option for 270 days', 'description_cn': '看跌期权270天 atm 默克尔波动率'} |
||||||
|
{'id': '1927', 'data_set_name': 'news_max_up_amt', 'description': 'The after the news high minus the price at the time of the news', 'description_cn': '新闻后 highs 减去 新闻时 price 的差值'} |
||||||
|
{'id': '2356', 'data_set_name': 'fn_comp_not_rec_stock_options_a', 'description': 'Unrecognized cost of unvested stock option awards.', 'description_cn': '未行权股票期权 unrecognized_cost_of_unvested_stock_options'} |
||||||
|
{'id': '2357', 'data_set_name': 'fn_comp_not_rec_stock_options_q', 'description': 'Unrecognized cost of unvested stock option awards.', 'description_cn': '未行权股票期权 unrecognized_cost_of_unvested_stock_options'} |
||||||
|
========================= 数据字段结束 ======================================= |
||||||
|
|
||||||
@ -0,0 +1,182 @@ |
|||||||
|
任务指令 |
||||||
|
需优化因子: scale(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10)) |
||||||
|
金融逻辑:该策略通过追踪期权市场上虚值看涨与看跌波动率的持续差值,捕捉市场对某只股票极端上涨的强烈且持续的投机情绪或对冲需求,并预期这种情绪会通过做市商的被动对冲行为或信息传递,最终转化为股价的实际动能。 |
||||||
|
核心假设:策略假设期权市场隐含了现货价格尚未反映的前瞻性情绪,且这种情绪具有持续性,更重要的是,做市商为对冲期权头寸而进行的现货买卖操作,会系统性推动价格向情绪预期的方向移动。 |
||||||
|
实施方案:每日计算各股票深度虚值看涨与看跌期权隐含波动率之差,并累加过去一段时间的差值形成动量信号,最后对整个股票池的该信号进行横截面标准化,据此构建多空组合进行交易。 |
||||||
|
优化建议:可以通过用平值波动率对差值进行标准化来剔除市场整体恐慌影响,并结合期权成交量进行过滤以排除流动性噪音,同时严格避开财报发布和期权到期等已知的波动率扭曲事件,以提升信号的纯净度和稳健性。 |
||||||
|
*=========================================================================================* |
||||||
|
输出格式: |
||||||
|
输出必须是且仅是纯文本。 |
||||||
|
每一行是一个完整、独立、语法正确的WebSim表达式。 |
||||||
|
严禁任何形式的解释、编号、标点包裹(如引号)、Markdown格式或额外文本。 |
||||||
|
===================== !!! 重点(输出方式) !!! ===================== |
||||||
|
现在,请严格遵守以上所有规则,开始生成可立即在WebSim中运行的复合因子表达式。 |
||||||
|
**输出格式**(一行一个表达式, 每个表达式中间需要添加一个空行, 只要表达式本身, 不要解释, 不需要序号, 也不要输出多余的东西): |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
... |
||||||
|
表达式 |
||||||
|
================================================================= |
||||||
|
重申:请确保所有表达式都使用WorldQuant WebSim平台函数,不要使用pandas、numpy或其他Python库函数。输出必须是一行有效的WQ表达式。 |
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 以及我提供的数据集, 进行生成,组合 20 个alpha: |
||||||
|
|
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 进行生成,组合因子 |
||||||
|
|
||||||
|
========================= 操作符开始 =======================================注意: Operator: 后面的是操作符, |
||||||
|
Description: 此字段后面的是操作符对应的描述或使用说明, Description字段后面的内容是使用说明, 不是操作符 |
||||||
|
特别注意!!!! 必须按照操作符字段Operator的使用说明生成 alphaOperator: abs(x) |
||||||
|
Description: Absolute value of x |
||||||
|
Operator: add(x, y, filter = false) |
||||||
|
Description: Add all inputs (at least 2 inputs required). If filter = true, filter all input NaN to 0 before adding |
||||||
|
Operator: densify(x) |
||||||
|
Description: Converts a grouping field of many buckets into lesser number of only available buckets so as to make working with grouping fields computationally efficient |
||||||
|
Operator: divide(x, y) |
||||||
|
Description: x / y |
||||||
|
Operator: inverse(x) |
||||||
|
Description: 1 / x |
||||||
|
Operator: log(x) |
||||||
|
Description: Natural logarithm. For example: Log(high/low) uses natural logarithm of high/low ratio as stock weights. |
||||||
|
Operator: max(x, y, ..) |
||||||
|
Description: Maximum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: min(x, y ..) |
||||||
|
Description: Minimum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: multiply(x ,y, ... , filter=false) |
||||||
|
Description: Multiply all inputs. At least 2 inputs are required. Filter sets the NaN values to 1 |
||||||
|
Operator: power(x, y) |
||||||
|
Description: x ^ y |
||||||
|
Operator: reverse(x) |
||||||
|
Description: - x |
||||||
|
Operator: sign(x) |
||||||
|
Description: if input > 0, return 1; if input < 0, return -1; if input = 0, return 0; if input = NaN, return NaN; |
||||||
|
Operator: signed_power(x, y) |
||||||
|
Description: x raised to the power of y such that final result preserves sign of x |
||||||
|
Operator: sqrt(x) |
||||||
|
Description: Square root of x |
||||||
|
Operator: subtract(x, y, filter=false) |
||||||
|
Description: x-y. If filter = true, filter all input NaN to 0 before subtracting |
||||||
|
Operator: and(input1, input2) |
||||||
|
Description: Logical AND operator, returns true if both operands are true and returns false otherwise |
||||||
|
Operator: if_else(input1, input2, input 3) |
||||||
|
Description: If input1 is true then return input2 else return input3. |
||||||
|
Operator: input1 < input2 |
||||||
|
Description: If input1 < input2 return true, else return false |
||||||
|
Operator: input1 <= input2 |
||||||
|
Description: Returns true if input1 <= input2, return false otherwise |
||||||
|
Operator: input1 == input2 |
||||||
|
Description: Returns true if both inputs are same and returns false otherwise |
||||||
|
Operator: input1 > input2 |
||||||
|
Description: Logic comparison operators to compares two inputs |
||||||
|
Operator: input1 >= input2 |
||||||
|
Description: Returns true if input1 >= input2, return false otherwise |
||||||
|
Operator: input1!= input2 |
||||||
|
Description: Returns true if both inputs are NOT the same and returns false otherwise |
||||||
|
Operator: is_nan(input) |
||||||
|
Description: If (input == NaN) return 1 else return 0 |
||||||
|
Operator: not(x) |
||||||
|
Description: Returns the logical negation of x. If x is true (1), it returns false (0), and if input is false (0), it returns true (1). |
||||||
|
Operator: or(input1, input2) |
||||||
|
Description: Logical OR operator returns true if either or both inputs are true and returns false otherwise |
||||||
|
Operator: days_from_last_change(x) |
||||||
|
Description: Amount of days since last change of x |
||||||
|
Operator: hump(x, hump = 0.01) |
||||||
|
Description: Limits amount and magnitude of changes in input (thus reducing turnover) |
||||||
|
Operator: kth_element(x, d, k) |
||||||
|
Description: Returns K-th value of input by looking through lookback days. This operator can be used to backfill missing data if k=1 |
||||||
|
Operator: last_diff_value(x, d) |
||||||
|
Description: Returns last x value not equal to current x value from last d days |
||||||
|
Operator: ts_arg_max(x, d) |
||||||
|
Description: Returns the relative index of the max value in the time series for the past d days. If the current day has the max value for the past d days, it returns 0. If previous day has the max value for the past d days, it returns 1 |
||||||
|
Operator: ts_arg_min(x, d) |
||||||
|
Description: Returns the relative index of the min value in the time series for the past d days; If the current day has the min value for the past d days, it returns 0; If previous day has the min value for the past d days, it returns 1. |
||||||
|
Operator: ts_av_diff(x, d) |
||||||
|
Description: Returns x - tsmean(x, d), but deals with NaNs carefully. That is NaNs are ignored during mean computation |
||||||
|
Operator: ts_backfill(x,lookback = d, k=1, ignore="NAN") |
||||||
|
Description: Backfill is the process of replacing the NAN or 0 values by a meaningful value (i.e., a first non-NaN value) |
||||||
|
Operator: ts_corr(x, y, d) |
||||||
|
Description: Returns correlation of x and y for the past d days |
||||||
|
Operator: ts_count_nans(x ,d) |
||||||
|
Description: Returns the number of NaN values in x for the past d days |
||||||
|
Operator: ts_covariance(y, x, d) |
||||||
|
Description: Returns covariance of y and x for the past d days |
||||||
|
Operator: ts_decay_linear(x, d, dense = false) |
||||||
|
Description: Returns the linear decay on x for the past d days. Dense parameter=false means operator works in sparse mode and we treat NaN as 0. In dense mode we do not. |
||||||
|
Operator: ts_delay(x, d) |
||||||
|
Description: Returns x value d days ago |
||||||
|
Operator: ts_delta(x, d) |
||||||
|
Description: Returns x - ts_delay(x, d) |
||||||
|
Operator: ts_mean(x, d) |
||||||
|
Description: Returns average value of x for the past d days. |
||||||
|
Operator: ts_product(x, d) |
||||||
|
Description: Returns product of x for the past d days |
||||||
|
Operator: ts_quantile(x,d, driver="gaussian" ) |
||||||
|
Description: It calculates ts_rank and apply to its value an inverse cumulative density function from driver distribution. Possible values of driver (optional ) are "gaussian", "uniform", "cauchy" distribution where "gaussian" is the default. |
||||||
|
Operator: ts_rank(x, d, constant = 0) |
||||||
|
Description: Rank the values of x for each instrument over the past d days, then return the rank of the current value + constant. If not specified, by default, constant = 0. |
||||||
|
Operator: ts_regression(y, x, d, lag = 0, rettype = 0) |
||||||
|
Description: Returns various parameters related to regression function |
||||||
|
Operator: ts_scale(x, d, constant = 0) |
||||||
|
Description: Returns (x - ts_min(x, d)) / (ts_max(x, d) - ts_min(x, d)) + constant. This operator is similar to scale down operator but acts in time series space |
||||||
|
Operator: ts_std_dev(x, d) |
||||||
|
Description: Returns standard deviation of x for the past d days |
||||||
|
Operator: ts_step(1) |
||||||
|
Description: Returns days' counter |
||||||
|
Operator: ts_sum(x, d) |
||||||
|
Description: Sum values of x for the past d days. |
||||||
|
Operator: ts_zscore(x, d) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean: (x - tsmean(x,d)) / tsstddev(x,d). This operator may help reduce outliers and drawdown. |
||||||
|
Operator: normalize(x, useStd = false, limit = 0.0) |
||||||
|
Description: Calculates the mean value of all valid alpha values for a certain date, then subtracts that mean from each element |
||||||
|
Operator: quantile(x, driver = gaussian, sigma = 1.0) |
||||||
|
Description: Rank the raw vector, shift the ranked Alpha vector, apply distribution (gaussian, cauchy, uniform). If driver is uniform, it simply subtract each Alpha value with the mean of all Alpha values in the Alpha vector |
||||||
|
Operator: rank(x, rate=2) |
||||||
|
Description: Ranks the input among all the instruments and returns an equally distributed number between 0.0 and 1.0. For precise sort, use the rate as 0 |
||||||
|
Operator: scale(x, scale=1, longscale=1, shortscale=1) |
||||||
|
Description: Scales input to booksize. We can also scale the long positions and short positions to separate scales by mentioning additional parameters to the operator |
||||||
|
Operator: winsorize(x, std=4) |
||||||
|
Description: Winsorizes x to make sure that all values in x are between the lower and upper limits, which are specified as multiple of std. |
||||||
|
Operator: zscore(x) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean |
||||||
|
Operator: vec_avg(x) |
||||||
|
Description: Taking mean of the vector field x |
||||||
|
Operator: vec_sum(x) |
||||||
|
Description: Sum of vector field x |
||||||
|
Operator: bucket(rank(x), range="0, 1, 0.1" or buckets = "2,5,6,7,10") |
||||||
|
Description: Convert float values into indexes for user-specified buckets. Bucket is useful for creating group values, which can be passed to GROUP as input |
||||||
|
Operator: trade_when(x, y, z) |
||||||
|
Description: Used in order to change Alpha values only under a specified condition and to hold Alpha values in other cases. It also allows to close Alpha positions (assign NaN values) under a specified condition |
||||||
|
Operator: group_backfill(x, group, d, std = 4.0) |
||||||
|
Description: If a certain value for a certain date and instrument is NaN, from the set of same group instruments, calculate winsorized mean of all non-NaN values over last d days |
||||||
|
Operator: group_mean(x, weight, group) |
||||||
|
Description: All elements in group equals to the mean |
||||||
|
Operator: group_neutralize(x, group) |
||||||
|
Description: Neutralizes Alpha against groups. These groups can be subindustry, industry, sector, country or a constant |
||||||
|
Operator: group_rank(x, group) |
||||||
|
Description: Each elements in a group is assigned the corresponding rank in this group |
||||||
|
Operator: group_scale(x, group) |
||||||
|
Description: Normalizes the values in a group to be between 0 and 1. (x - groupmin) / (groupmax - groupmin) |
||||||
|
Operator: group_zscore(x, group) |
||||||
|
Description: Calculates group Z-score - numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean. zscore = (data - mean) / stddev of x for each instrument within its group. |
||||||
|
========================= 操作符结束 ======================================= |
||||||
|
|
||||||
|
========================= 数据字段开始 ======================================= |
||||||
|
注意: data_set_name: 后面的是数据字段(可以使用), description: 此字段后面的是数据字段对应的描述或使用说明(不能使用), description_cn字段后面的内容是中文使用说明(不能使用) |
||||||
|
|
||||||
|
{'id': '517', 'data_set_name': 'fnd6_newqeventv110_glceaq', 'description': 'Gain/Loss on Sale (Core Earnings Adjusted) After-tax', 'description_cn': '税后核心 earnings 润亏'} |
||||||
|
{'id': '624', 'data_set_name': 'fnd6_newqeventv110_spcedq', 'description': 'S&P Core Earnings EPS Diluted', 'description_cn': 'SPCE earnings per share diluted'} |
||||||
|
{'id': '625', 'data_set_name': 'fnd6_newqeventv110_spceeps12', 'description': 'S&P Core Earnings EPS Basic 12MM', 'description_cn': '标普核心 earnings 每股基本值_12M'} |
||||||
|
{'id': '628', 'data_set_name': 'fnd6_newqeventv110_spceepsq', 'description': 'S&P Core Earnings EPS Basic', 'description_cn': '标普核心 earnings 每股基本值'} |
||||||
|
{'id': '629', 'data_set_name': 'fnd6_newqeventv110_spcep12', 'description': 'S&P Core Earnings 12MM - Preliminary', 'description_cn': '标普核心 earnings 12个月 - 预liminary'} |
||||||
|
{'id': '630', 'data_set_name': 'fnd6_newqeventv110_spcepd12', 'description': 'S&P Core Earnings 12MM EPS Diluted - Preliminary', 'description_cn': 'S&P核心 earnings_12个月稀释后每股盈亏平衡点_初步'} |
||||||
|
{'id': '774', 'data_set_name': 'fnd6_newqv1300_spcedq', 'description': 'S&P Core Earnings EPS Diluted', 'description_cn': '标准普尔核心 earnings 每股稀释后利润'} |
||||||
|
{'id': '777', 'data_set_name': 'fnd6_newqv1300_spceepsq', 'description': 'S&P Core Earnings EPS Basic', 'description_cn': '标普核心 earnings EPS 基本'} |
||||||
|
{'id': '872', 'data_set_name': 'fnd6_spce', 'description': 'S&P Core Earnings', 'description_cn': '标准普尔核心 earnings'} |
||||||
|
{'id': '1292', 'data_set_name': 'anl4_netdebt_flag', 'description': 'Net debt - forecast type (revision/new/...)', 'description_cn': '净负债-预测类型(修正值/新值/....ImageAlign\n<|im_start|>user\nstrike price'} |
||||||
|
{'id': '1861', 'data_set_name': 'implied_volatility_call_60', 'description': 'At-the-money option-implied volatility for call Option for 60 days', 'description_cn': '看涨期权60天 atm 隐含波动率'} |
||||||
|
{'id': '1894', 'data_set_name': 'implied_volatility_put_270', 'description': 'At-the-money option-implied volatility for Put Option for 270 days', 'description_cn': '看跌期权270天 atm 默克尔波动率'} |
||||||
|
{'id': '1927', 'data_set_name': 'news_max_up_amt', 'description': 'The after the news high minus the price at the time of the news', 'description_cn': '新闻后 highs 减去 新闻时 price 的差值'} |
||||||
|
{'id': '2356', 'data_set_name': 'fn_comp_not_rec_stock_options_a', 'description': 'Unrecognized cost of unvested stock option awards.', 'description_cn': '未行权股票期权 unrecognized_cost_of_unvested_stock_options'} |
||||||
|
{'id': '2357', 'data_set_name': 'fn_comp_not_rec_stock_options_q', 'description': 'Unrecognized cost of unvested stock option awards.', 'description_cn': '未行权股票期权 unrecognized_cost_of_unvested_stock_options'} |
||||||
|
========================= 数据字段结束 ======================================= |
||||||
|
|
||||||
|
以上数据字段和操作符, 按照Description说明组合, 但是每一个 alpha 组合的使用的数据字段和操作符不要过于集中, 在符合语法的情况下, 多尝试不同的组合 |
||||||
@ -0,0 +1,170 @@ |
|||||||
|
任务指令 |
||||||
|
需优化因子: scale(ts_sum(subtract(implied_volatility_call_120, implied_volatility_put_90), 10)) |
||||||
|
金融逻辑:该策略通过追踪期权市场上虚值看涨与看跌波动率的持续差值,捕捉市场对某只股票极端上涨的强烈且持续的投机情绪或对冲需求,并预期这种情绪会通过做市商的被动对冲行为或信息传递,最终转化为股价的实际动能。 |
||||||
|
核心假设:策略假设期权市场隐含了现货价格尚未反映的前瞻性情绪,且这种情绪具有持续性,更重要的是,做市商为对冲期权头寸而进行的现货买卖操作,会系统性推动价格向情绪预期的方向移动。 |
||||||
|
实施方案:每日计算各股票深度虚值看涨与看跌期权隐含波动率之差,并累加过去一段时间的差值形成动量信号,最后对整个股票池的该信号进行横截面标准化,据此构建多空组合进行交易。 |
||||||
|
优化建议:可以通过用平值波动率对差值进行标准化来剔除市场整体恐慌影响,并结合期权成交量进行过滤以排除流动性噪音,同时严格避开财报发布和期权到期等已知的波动率扭曲事件,以提升信号的纯净度和稳健性。 |
||||||
|
*=========================================================================================* |
||||||
|
输出格式: |
||||||
|
输出必须是且仅是纯文本。 |
||||||
|
每一行是一个完整、独立、语法正确的WebSim表达式。 |
||||||
|
严禁任何形式的解释、编号、标点包裹(如引号)、Markdown格式或额外文本。 |
||||||
|
===================== !!! 重点(输出方式) !!! ===================== |
||||||
|
现在,请严格遵守以上所有规则,开始生成可立即在WebSim中运行的复合因子表达式。 |
||||||
|
**输出格式**(一行一个表达式, 每个表达式中间需要添加一个空行, 只要表达式本身, 不要解释, 不需要序号, 也不要输出多余的东西): |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
表达式 |
||||||
|
... |
||||||
|
表达式 |
||||||
|
================================================================= |
||||||
|
重申:请确保所有表达式都使用WorldQuant WebSim平台函数,不要使用pandas、numpy或其他Python库函数。输出必须是一行有效的WQ表达式。 |
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 以及我提供的数据集, 进行生成,组合 20 个alpha: |
||||||
|
|
||||||
|
以下是我的账号有权限使用的操作符, 请严格按照操作符, 进行生成,组合因子 |
||||||
|
|
||||||
|
========================= 操作符开始 =======================================注意: Operator: 后面的是操作符, |
||||||
|
Description: 此字段后面的是操作符对应的描述或使用说明, Description字段后面的内容是使用说明, 不是操作符 |
||||||
|
特别注意!!!! 必须按照操作符字段Operator的使用说明生成 alphaOperator: abs(x) |
||||||
|
Description: Absolute value of x |
||||||
|
Operator: add(x, y, filter = false) |
||||||
|
Description: Add all inputs (at least 2 inputs required). If filter = true, filter all input NaN to 0 before adding |
||||||
|
Operator: densify(x) |
||||||
|
Description: Converts a grouping field of many buckets into lesser number of only available buckets so as to make working with grouping fields computationally efficient |
||||||
|
Operator: divide(x, y) |
||||||
|
Description: x / y |
||||||
|
Operator: inverse(x) |
||||||
|
Description: 1 / x |
||||||
|
Operator: log(x) |
||||||
|
Description: Natural logarithm. For example: Log(high/low) uses natural logarithm of high/low ratio as stock weights. |
||||||
|
Operator: max(x, y, ..) |
||||||
|
Description: Maximum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: min(x, y ..) |
||||||
|
Description: Minimum value of all inputs. At least 2 inputs are required |
||||||
|
Operator: multiply(x ,y, ... , filter=false) |
||||||
|
Description: Multiply all inputs. At least 2 inputs are required. Filter sets the NaN values to 1 |
||||||
|
Operator: power(x, y) |
||||||
|
Description: x ^ y |
||||||
|
Operator: reverse(x) |
||||||
|
Description: - x |
||||||
|
Operator: sign(x) |
||||||
|
Description: if input > 0, return 1; if input < 0, return -1; if input = 0, return 0; if input = NaN, return NaN; |
||||||
|
Operator: signed_power(x, y) |
||||||
|
Description: x raised to the power of y such that final result preserves sign of x |
||||||
|
Operator: sqrt(x) |
||||||
|
Description: Square root of x |
||||||
|
Operator: subtract(x, y, filter=false) |
||||||
|
Description: x-y. If filter = true, filter all input NaN to 0 before subtracting |
||||||
|
Operator: and(input1, input2) |
||||||
|
Description: Logical AND operator, returns true if both operands are true and returns false otherwise |
||||||
|
Operator: if_else(input1, input2, input 3) |
||||||
|
Description: If input1 is true then return input2 else return input3. |
||||||
|
Operator: input1 < input2 |
||||||
|
Description: If input1 < input2 return true, else return false |
||||||
|
Operator: input1 <= input2 |
||||||
|
Description: Returns true if input1 <= input2, return false otherwise |
||||||
|
Operator: input1 == input2 |
||||||
|
Description: Returns true if both inputs are same and returns false otherwise |
||||||
|
Operator: input1 > input2 |
||||||
|
Description: Logic comparison operators to compares two inputs |
||||||
|
Operator: input1 >= input2 |
||||||
|
Description: Returns true if input1 >= input2, return false otherwise |
||||||
|
Operator: input1!= input2 |
||||||
|
Description: Returns true if both inputs are NOT the same and returns false otherwise |
||||||
|
Operator: is_nan(input) |
||||||
|
Description: If (input == NaN) return 1 else return 0 |
||||||
|
Operator: not(x) |
||||||
|
Description: Returns the logical negation of x. If x is true (1), it returns false (0), and if input is false (0), it returns true (1). |
||||||
|
Operator: or(input1, input2) |
||||||
|
Description: Logical OR operator returns true if either or both inputs are true and returns false otherwise |
||||||
|
Operator: days_from_last_change(x) |
||||||
|
Description: Amount of days since last change of x |
||||||
|
Operator: hump(x, hump = 0.01) |
||||||
|
Description: Limits amount and magnitude of changes in input (thus reducing turnover) |
||||||
|
Operator: kth_element(x, d, k) |
||||||
|
Description: Returns K-th value of input by looking through lookback days. This operator can be used to backfill missing data if k=1 |
||||||
|
Operator: last_diff_value(x, d) |
||||||
|
Description: Returns last x value not equal to current x value from last d days |
||||||
|
Operator: ts_arg_max(x, d) |
||||||
|
Description: Returns the relative index of the max value in the time series for the past d days. If the current day has the max value for the past d days, it returns 0. If previous day has the max value for the past d days, it returns 1 |
||||||
|
Operator: ts_arg_min(x, d) |
||||||
|
Description: Returns the relative index of the min value in the time series for the past d days; If the current day has the min value for the past d days, it returns 0; If previous day has the min value for the past d days, it returns 1. |
||||||
|
Operator: ts_av_diff(x, d) |
||||||
|
Description: Returns x - tsmean(x, d), but deals with NaNs carefully. That is NaNs are ignored during mean computation |
||||||
|
Operator: ts_backfill(x,lookback = d, k=1, ignore="NAN") |
||||||
|
Description: Backfill is the process of replacing the NAN or 0 values by a meaningful value (i.e., a first non-NaN value) |
||||||
|
Operator: ts_corr(x, y, d) |
||||||
|
Description: Returns correlation of x and y for the past d days |
||||||
|
Operator: ts_count_nans(x ,d) |
||||||
|
Description: Returns the number of NaN values in x for the past d days |
||||||
|
Operator: ts_covariance(y, x, d) |
||||||
|
Description: Returns covariance of y and x for the past d days |
||||||
|
Operator: ts_decay_linear(x, d, dense = false) |
||||||
|
Description: Returns the linear decay on x for the past d days. Dense parameter=false means operator works in sparse mode and we treat NaN as 0. In dense mode we do not. |
||||||
|
Operator: ts_delay(x, d) |
||||||
|
Description: Returns x value d days ago |
||||||
|
Operator: ts_delta(x, d) |
||||||
|
Description: Returns x - ts_delay(x, d) |
||||||
|
Operator: ts_mean(x, d) |
||||||
|
Description: Returns average value of x for the past d days. |
||||||
|
Operator: ts_product(x, d) |
||||||
|
Description: Returns product of x for the past d days |
||||||
|
Operator: ts_quantile(x,d, driver="gaussian" ) |
||||||
|
Description: It calculates ts_rank and apply to its value an inverse cumulative density function from driver distribution. Possible values of driver (optional ) are "gaussian", "uniform", "cauchy" distribution where "gaussian" is the default. |
||||||
|
Operator: ts_rank(x, d, constant = 0) |
||||||
|
Description: Rank the values of x for each instrument over the past d days, then return the rank of the current value + constant. If not specified, by default, constant = 0. |
||||||
|
Operator: ts_regression(y, x, d, lag = 0, rettype = 0) |
||||||
|
Description: Returns various parameters related to regression function |
||||||
|
Operator: ts_scale(x, d, constant = 0) |
||||||
|
Description: Returns (x - ts_min(x, d)) / (ts_max(x, d) - ts_min(x, d)) + constant. This operator is similar to scale down operator but acts in time series space |
||||||
|
Operator: ts_std_dev(x, d) |
||||||
|
Description: Returns standard deviation of x for the past d days |
||||||
|
Operator: ts_step(1) |
||||||
|
Description: Returns days' counter |
||||||
|
Operator: ts_sum(x, d) |
||||||
|
Description: Sum values of x for the past d days. |
||||||
|
Operator: ts_zscore(x, d) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean: (x - tsmean(x,d)) / tsstddev(x,d). This operator may help reduce outliers and drawdown. |
||||||
|
Operator: normalize(x, useStd = false, limit = 0.0) |
||||||
|
Description: Calculates the mean value of all valid alpha values for a certain date, then subtracts that mean from each element |
||||||
|
Operator: quantile(x, driver = gaussian, sigma = 1.0) |
||||||
|
Description: Rank the raw vector, shift the ranked Alpha vector, apply distribution (gaussian, cauchy, uniform). If driver is uniform, it simply subtract each Alpha value with the mean of all Alpha values in the Alpha vector |
||||||
|
Operator: rank(x, rate=2) |
||||||
|
Description: Ranks the input among all the instruments and returns an equally distributed number between 0.0 and 1.0. For precise sort, use the rate as 0 |
||||||
|
Operator: scale(x, scale=1, longscale=1, shortscale=1) |
||||||
|
Description: Scales input to booksize. We can also scale the long positions and short positions to separate scales by mentioning additional parameters to the operator |
||||||
|
Operator: winsorize(x, std=4) |
||||||
|
Description: Winsorizes x to make sure that all values in x are between the lower and upper limits, which are specified as multiple of std. |
||||||
|
Operator: zscore(x) |
||||||
|
Description: Z-score is a numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean |
||||||
|
Operator: vec_avg(x) |
||||||
|
Description: Taking mean of the vector field x |
||||||
|
Operator: vec_sum(x) |
||||||
|
Description: Sum of vector field x |
||||||
|
Operator: bucket(rank(x), range="0, 1, 0.1" or buckets = "2,5,6,7,10") |
||||||
|
Description: Convert float values into indexes for user-specified buckets. Bucket is useful for creating group values, which can be passed to GROUP as input |
||||||
|
Operator: trade_when(x, y, z) |
||||||
|
Description: Used in order to change Alpha values only under a specified condition and to hold Alpha values in other cases. It also allows to close Alpha positions (assign NaN values) under a specified condition |
||||||
|
Operator: group_backfill(x, group, d, std = 4.0) |
||||||
|
Description: If a certain value for a certain date and instrument is NaN, from the set of same group instruments, calculate winsorized mean of all non-NaN values over last d days |
||||||
|
Operator: group_mean(x, weight, group) |
||||||
|
Description: All elements in group equals to the mean |
||||||
|
Operator: group_neutralize(x, group) |
||||||
|
Description: Neutralizes Alpha against groups. These groups can be subindustry, industry, sector, country or a constant |
||||||
|
Operator: group_rank(x, group) |
||||||
|
Description: Each elements in a group is assigned the corresponding rank in this group |
||||||
|
Operator: group_scale(x, group) |
||||||
|
Description: Normalizes the values in a group to be between 0 and 1. (x - groupmin) / (groupmax - groupmin) |
||||||
|
Operator: group_zscore(x, group) |
||||||
|
Description: Calculates group Z-score - numerical measurement that describes a value's relationship to the mean of a group of values. Z-score is measured in terms of standard deviations from the mean. zscore = (data - mean) / stddev of x for each instrument within its group. |
||||||
|
========================= 操作符结束 ======================================= |
||||||
|
|
||||||
|
========================= 数据字段开始 ======================================= |
||||||
|
注意: data_set_name: 后面的是数据字段(可以使用), description: 此字段后面的是数据字段对应的描述或使用说明(不能使用), description_cn字段后面的内容是中文使用说明(不能使用) |
||||||
|
|
||||||
|
{'id': '35', 'data_set_name': 'option_breakeven_720', 'description': "Price at which a stock's options with expiration 720 days in the future break even based on its recent bid/ask mean.", 'description_cn': '基于最近的_bid_emean_盈亏平衡点_720天后到期的股票期权价格'} |
||||||
|
{'id': '989', 'data_set_name': 'fscore_bfl_total', 'description': 'The final score M-Score is a weighted average of both the Pentagon surface score and the Pentagon acceleration score.', 'description_cn': '最终得分M-_score=五角大楼表面评分与五角加速评分加权平均值'} |
||||||
|
{'id': '1682', 'data_set_name': 'pv13_com_rk_au', 'description': 'the HITS authority score of competitors', 'description_cn': '竞品 Hits 权重分'} |
||||||
|
========================= 数据字段结束 ======================================= |
||||||
|
|
||||||
|
以上数据字段和操作符, 按照Description说明组合, 但是每一个 alpha 组合的使用的数据字段和操作符不要过于集中, 在符合语法的情况下, 多尝试不同的组合 |
||||||
Loading…
Reference in new issue