股票要盈利,只能低买高卖,找到低点是关键。
看下面的几个个股走势:
以上几个图片不是专门找的,只是随机在同花顺的个股K线图中的截图,在箭头指向的位置,有大阴线和长下影线结合的条件下,可以看作是个股的阶段性低点,后续都是企稳震荡或者小幅上涨的行情,在短期内是有盈利机会的,可以视作短线操作的入口参考。
将选股操作放到数据层面,如果有一份个股的历史行情数据,包含日期、代码、价格、涨跌幅、最低价、最高价、换手率等信息,还有一份个股的基础信息数据,包含代码、流通股本、行业、市盈率等基础信息。基于这些数据,可以做简单的筛选,找出上面图片中的地点位置,重点就在于大阴线和下引线的筛选上。
1.找到大阴线的数据,结合量价关系分析,过滤个股市值、当日换手率、阴线幅度、日期范围、板块等;
select t.day,t.code,t.stockname,t.price,t.risepct,t.exchangepct ,t.turnover
,i.ttm,round(i.ltg*t.price/100000000,3) 流通市值_亿
from his t left join info i on i.code=t.code
where t.exchangepct>6 --换手率,洗盘、出货程度
and t.risepct<-8 and t.risepct>-21 --下杀力度,-21排除新股次新股下跌幅度数据
and t.day>'2025-01-01' --时间段,可结合大盘涨跌阶段
and i.ltg*t.price>200000000 and i.ltg*t.price<3000000000 --流通市值,20亿~300亿,剔除微盘和大盘
and i.ttm >-50 and i.ttm<50 --市盈率
and t.code not like '688%' --不喜欢的板块
and lower(t.stockname) not like '%st%' --去掉ST
2.找到大阴线后出现下影线的位置日期,同时再筛选一下其他条件
select
tt.code,tt.stockname,tt.ttm,tt.流通市值_亿
--阴线日行情
,'阴线日行情',tt.day,tt.price,tt.risepct,tt.exchangepct,round(tt.turnover/10000,3) 成交额_亿
--下影线日行情
,'下影线日行情',t1.day,t1.price,t1.risepct,t1.exchangepct,round(t1.turnover/10000,3) 成交额_亿
--影线幅度
,round(case when t1.price<=t1.startprice then (t1.price-t1.daymin)/t1.price*100 else (t1.startprice-t1.daymin)/t1.startprice*100 end,3) 下影线幅度
,round((tt.price-t1.price)/tt.price,3)*100 下跌幅度
from
(
select t.day,t.code,t.stockname,t.price,t.risepct,t.exchangepct
from his t left join info i on i.code=t.code
where t.exchangepct>6 --换手率,洗盘、出货程度
and t.risepct<-8 and t.risepct>-21 --下杀力度,-21排除新股次新股下跌幅度数据
and t.day>'2025-01-01' --时间段,可结合大盘涨跌阶段
and i.ltg*t.price>200000000 and i.ltg*t.price<3000000000 --流通市值,20亿~300亿,剔除微盘和大盘
and i.ttm >-50 and i.ttm<50 --市盈率
and t.code not like '688%' --不喜欢的板块
and lower(t.stockname) not like '%st%' --去掉ST
) tt --阴线
left join his t1 on t1.code=tt.code --下影线
where t1.day>tt.day --下影线在阴线之后
and (
(t1.price<=t1.startprice and t1.price>t1.daymin*1.05) --绿柱,对比收盘价,影线幅度5%,也可以直接筛选涨跌幅
or (t1.price>t1.startprice and t1.startprice>t1.daymin*1.05)--红柱,对比开盘价,影线幅度5%
)
and tt.price > t1.price*1.2 --下影线日价格对比阴线日是下跌的,下杀力度,模糊匹配跌了20个点吧,
and t1.exchangepct >8 --下影线日换手充分
and t1.exchangepct<30 --下影线日主力出货跑路的不要
通过上面的查询结果来看,大阴线常有,而大幅度的下影线不常有(通常都是伴随大盘的下杀反弹)。这里只是说明一种选股思路,查询的筛选条件太多,每一个条件都会过滤掉很多个股,单市盈率为负一个条件就过滤掉了1500只,流通市值20~300亿过滤了1500只,需要结合大盘行情和市场炒作风格灵活调整。