Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
A
alpha-mind
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dr.李
alpha-mind
Commits
186b5f4b
Commit
186b5f4b
authored
Jun 30, 2017
by
Dr.李
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update to reflect the schema change
parent
e07f1d0c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
models.py
alphamind/data/dbmodel/models.py
+4
-4
update_uqer_data.py
scripts/update_uqer_data.py
+1
-1
No files found.
alphamind/data/dbmodel/models.py
View file @
186b5f4b
...
...
@@ -24,10 +24,10 @@ class DailyReturn(Base):
d1
=
Column
(
Float
)
class
Facto
r
(
Base
):
__tablename__
=
'
factors
'
class
Uqe
r
(
Base
):
__tablename__
=
'
uqer
'
__table_args__
=
(
Index
(
'
factors
_Date_Code_uindex'
,
'Date'
,
'Code'
,
unique
=
True
),
Index
(
'
uqer
_Date_Code_uindex'
,
'Date'
,
'Code'
,
unique
=
True
),
)
Date
=
Column
(
DateTime
,
primary_key
=
True
,
nullable
=
False
)
...
...
@@ -839,7 +839,7 @@ class Strategy(Base):
Date
=
Column
(
DateTime
,
primary_key
=
True
,
nullable
=
False
)
strategyName
=
Column
(
String
(
20
),
primary_key
=
True
,
nullable
=
False
)
factor
=
Column
(
String
(
2
0
),
primary_key
=
True
,
nullable
=
False
)
factor
=
Column
(
String
(
5
0
),
primary_key
=
True
,
nullable
=
False
)
weight
=
Column
(
Float
)
source
=
Column
(
String
(
20
))
...
...
scripts/update_uqer_data.py
View file @
186b5f4b
...
...
@@ -64,7 +64,7 @@ def update_uqer_factors(ds, **kwargs):
df
.
Code
=
df
.
Code
.
astype
(
int
)
del
df
[
'secID'
]
table
=
'
factors
'
table
=
'
uqer
'
engine
.
execute
(
"delete from {0} where Date = '{1}';"
.
format
(
table
,
ref_date
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment