GetHighLowPrice(数据库)
定义
public List<(string Code, Decimal High, Decimal Low)> GetHighLowPrice(int daysCount, DateTime date, List<string> Codes)
描述
获取区间最高最低价格,获取字段为High,Low
参数
参数名 |
类型 |
描述 |
daysCount |
int |
天数 |
date |
DateTime |
时间,不含当天 |
Codes |
List<string> |
股票代码 |
返回值
返回值 |
类型 |
描述 |
result |
List<(string Code, Decimal High, Decimal Low)> |
数据实体 |
示例
public override void OnData(Slice slice)
{
//获取股票60天的最高价和最低价
var result = GetHighLowPrice(60, Time, ["000001.XSHE"]);
foreach(var res in result){
Print($"股票:{res.Code},最高价:{res.High},最低价:{res.Low}");
}
}