- 博客(15)
- 资源 (9)
- 问答 (2)
- 收藏
- 关注
原创 python_numpy_计算对数收益率和还原问题
可以使用np.log和np.exp这两个:x=5000y=6000ret=np.log(float(6000)/float(5000))print retnew_y=6000/float(np.exp(ret))print new_y#举一个更加复杂的例子:import pandas as pdimport numpy as np#计算收益率x=range(0,1000
2017-06-30 12:27:47 9849
原创 python常用统计量的计算
# -*- coding: utf-8 -*-"""Created on Tue Jun 27 09:19:25 2017@author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyone else."""import pandas as pd import s
2017-06-27 10:07:26 5876
原创 python-检验33品种数据是否是正态分布
# -*- coding: utf-8 -*-"""Created on Thu Jun 22 17:03:16 2017@author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyone else."""import pandas as pdimport num
2017-06-23 15:50:52 4984
原创 python-33品种随机游走检验
# -*- coding: utf-8 -*-"""Created on Thu Jun 22 17:03:16 2017@author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyone else."""import pandas as pdimport num
2017-06-23 15:15:23 1736
原创 python-33品种期货自相关系数
# -*- coding: utf-8 -*-"""Created on Thu Jun 22 17:03:16 2017@author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyone else."""import pandas as pdimport num
2017-06-23 14:45:14 2721
原创 python-期货指数的单位根检验
代码如下: 测试结果表明,以下33个品种不存在单位根.# -*- coding: utf-8 -*-"""Created on Thu Jun 22 17:03:16 2017@author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyo
2017-06-23 13:49:12 3519 2
原创 spss、R语言、Python数据分析系列(7):python-adf单位根检验
import pandas as pdimport numpy as npimport matplotlib.pyplot as pltimport statsmodels.tsa.stattools as tsdata=pd.read_csv('C:/Users/HXWD/Desktop/数据/rb.csv',encoding='gbk')data.columns=['date','o
2017-06-23 11:17:10 7905 2
原创 spss、R语言、Python数据分析系列(6):R语言adf单位根检验
data<-read.table('C:/Users/HXWD/Desktop/数据/rb.csv',header=TRUE,sep=',')data=data[,5]head(data)data=log(data)head(data)adf.test(data,k = 1)#读取数据,取对数,并进行单位根检验Augmented Dickey-Fuller Testd
2017-06-23 11:08:20 28332 3
转载 python常用模块platform的基本用法
import platform ''''' python中,platform模块给我们提供了很多方法去获取操作系统的信息 如: import platform platform.platform() #获取操作系统名称及版本号,'Linux-3.13.0-46-generic-i686-with-Deepin-2014
2017-06-15 14:25:22 6054
原创 python os模块学习笔记
# -*- coding: utf-8 -*-"""Created on Thu Jun 15 10:25:15 2017@author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyone else."""import os#显示当前的工作平台,'posix'代表
2017-06-15 11:13:37 507
原创 mongodb安装windows 服务 发生服务特定错误100
按照百度经验这篇文章安装mongodb,http://jingyan.baidu.com/article/6b97984dbeef881ca2b0bf3e.html出现net start monogodb 无法启动的现象。推测应该是安装windows服务启动的时候mongodb应该是打开的,关闭mongodb之后就可以了。参考解决办法:http://jingyan.baidu.co
2017-06-12 09:13:13 3510 1
原创 python双均线预测能力检验3
# -*- coding: utf-8 -*-"""Created on Wed Jun 7 10:22:18 2017@author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyone else."""import pandas as pd import n
2017-06-08 10:52:59 1374
原创 python-双均线预测能力检验2
# -*- coding: utf-8 -*- """ Created on Thu May 25 08:55:12 2017 @author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyone else. """ import pandas as p
2017-06-08 10:23:46 944
原创 python-双均线策略的预测能力研究
做量化,不仅要懂编程,有交易经验,而且要数学和统计学要好。恶补统计理论中,好后悔上统计课的时候做白日梦了。。。。。。。。。。。下面试着尝试了分析双均线能否产生预测力,我们知道很多回测产生的盈利,有时候并不是策略本身的问题,有可能是数据的趋势。本文尝试通过消除平均趋势或者采用随机基准来对比策略的收益,似乎,双均线蛮好。# -*- coding: utf-8 -*-"""Creat
2017-06-06 17:33:15 5219
原创 python机器学习预测学习笔记(有点问题)
# -*- coding: utf-8 -*-"""Created on Wed May 24 17:19:23 2017@author: yunjinqi E-mail:yunjinqi@qq.com Differentiate yourself in the world from anyone else."""import pandas as pdfrom sklea
2017-06-06 14:37:01 1220
03、债券策略需要的数据.rar
2020-07-26
python forfinance---code
2017-01-19
珠心神算-最简洁的锻炼数学计算的小程序
2016-10-30
改写c++进行adf检验的函数代码
2024-07-17
使用python编写一个函数,能够根据均值、标准差、偏度和峰度生成n个随机数
2022-10-12
如何把网站和某些关键字进行绑定?
2022-03-18
TA创建的收藏夹 TA关注的收藏夹
TA关注的人