This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$FolderPath = Get-ChildItem -Directory -Path "C:\temp\" -Recurse -Force | |
$Output = @() | |
ForEach ($Folder in $FolderPath) { | |
$Acl = Get-Acl -Path $Folder.FullName | |
ForEach ($Access in $Acl.Access) { | |
$Properties = [ordered]@{'Folder Name'=$Folder.FullName;'Group/User'=$Access.IdentityReference;'Permissions'=$Access.FileSystemRights;'Inherited'=$Access.IsInherited} | |
$Output += New-Object -TypeName PSObject -Property $Properties | |
} | |
} | |
$Output | Out-GridView |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://www.kaggle.com/dimitreoliveira/deep-learning-for-time-series-forecasting | |
def series_to_supervised(data, window=1, lag=1, dropnan=True): | |
cols, names = list(), list() | |
# Input sequence (t-n, ... t-1) | |
for i in range(window, 0, -1): | |
cols.append(data.shift(i)) | |
names += [('%s(t-%d)' % (col, i)) for col in data.columns] | |
# Current timestep (t=0) | |
cols.append(data) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// http://channel9.msdn.com/Events/Build/2013/2-401 | |
// http://www.quaetrix.com/Build2013.html | |
using System; | |
// For 2013 Microsoft Build Conference attendees | |
// June 25-28, 2013 | |
// San Francisco, CA | |
// | |
// This is source for a C# console application. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pandas import DataFrame | |
from pandas import concat | |
def series_to_supervised(data, n_in=1, n_out=1, dropnan=True): | |
""" | |
Frame a time series as a supervised learning dataset. | |
Arguments: | |
data: Sequence of observations as a list or NumPy array. | |
n_in: Number of lag observations as input (X). | |
n_out: Number of observations as output (y). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pandas import Series | |
from statsmodels.tsa.stattools import adfuller | |
def test_stationarity(timeseries, windowroll = 12, cutoff = 0.05): | |
#Determing rolling statistics | |
rolmean = pd.rolling_mean(timeseries, window=windowroll) | |
rolstd = pd.rolling_std(timeseries, window=windowroll) | |
#Plot rolling statistics: | |
orig = plt.plot(timeseries, color='blue',label='Original') | |
mean = plt.plot(rolmean, color='red', label='Rolling Mean') | |
std = plt.plot(rolstd, color='black', label = 'Rolling Std') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT [DateTime], [Close] | |
,(log([Close]) - log(LAG ([Close],1) OVER (ORDER BY [DateTime])))*100 AS LogReturn | |
FROM [EURUSD_Daily_198001020000_201805180000_Quant] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT [DateTime] | |
,([Close] - LAG ([Close],1) OVER (ORDER BY [DateTime]))/LAG ([Close],1) OVER (ORDER BY [DateTime])*100 AS pct_change_close_1 | |
,([Close] - LAG ([Close],2) OVER (ORDER BY [DateTime]))/LAG ([Close],2) OVER (ORDER BY [DateTime])*100 AS pct_change_close_2 | |
,([Close] - LAG ([Close],3) OVER (ORDER BY [DateTime]))/LAG ([Close],3) OVER (ORDER BY [DateTime])*100 AS pct_change_close_3 | |
,([Close] - LAG ([Close],4) OVER (ORDER BY [DateTime]))/LAG ([Close],4) OVER (ORDER BY [DateTime])*100 AS pct_change_close_4 | |
,([Close] - LAG ([Close],5) OVER (ORDER BY [DateTime]))/LAG ([Close],5) OVER (ORDER BY [DateTime])*100 AS pct_change_close_5 | |
,([Close] - LAG ([Close],6) OVER (ORDER BY [DateTime]))/LAG ([Close],6) OVER (ORDER BY [DateTime])*100 AS pct_change_close_6 | |
,([Close] - LAG ([Close],7) OVER (ORDER BY [DateTime]))/LAG ([Close],7) OVER (ORDER BY [DateTime])*100 AS pct_change_close_7 | |
,([Close] - LAG ([Close],8) OVER (ORDER BY [DateTime]))/LAG ([Close],8) OVER (ORDER BY [DateTime])*100 AS pct_change_close_8 | |
,([Cl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import * | |
app = Flask(__name__) | |
@app.route('/post', methods = ['POST']) | |
def post(): | |
json = request.json | |
encoded = request.form | |
cp1_ = (encoded.get("cp1")) | |
cp2_ = (encoded.get("cp2")) | |
cp3_ = (encoded.get("cp3")) | |
cp4_ = (encoded.get("cp4")) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT [DateTime],[Close] | |
,([Close] - LAG ([Close],1) OVER (ORDER BY [DateTime]))/LAG ([Close],1) OVER (ORDER BY [DateTime])*100 AS PCT_CHANGE_CLOSE | |
FROM [dbsec].[dbo].[EURUSDM1FiboMA]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select * | |
,CASE WHEN ROW_NUMBER() OVER (ORDER BY [Datetime]) > 1 THEN SUM([Close]) OVER (ORDER BY [Datetime] ROWS BETWEEN 1 PRECEDING AND CURRENT ROW) END/2 as MA2 | |
,CASE WHEN ROW_NUMBER() OVER (ORDER BY [Datetime]) > 2 THEN SUM([Close]) OVER (ORDER BY [Datetime] ROWS BETWEEN 2 PRECEDING AND CURRENT ROW) END/3 as MA3 | |
,CASE WHEN ROW_NUMBER() OVER (ORDER BY [Datetime]) > 4 THEN SUM([Close]) OVER (ORDER BY [Datetime] ROWS BETWEEN 4 PRECEDING AND CURRENT ROW) END/4 as MA5 | |
,CASE WHEN ROW_NUMBER() OVER (ORDER BY [Datetime]) > 7 THEN SUM([Close]) OVER (ORDER BY [Datetime] ROWS BETWEEN 7 PRECEDING AND CURRENT ROW) END/8 as MA8 | |
,CASE WHEN ROW_NUMBER() OVER (ORDER BY [Datetime]) > 12 THEN SUM([Close]) OVER (ORDER BY [Datetime] ROWS BETWEEN 12 PRECEDING AND CURRENT ROW) END/13 as MA13 | |
,CASE WHEN ROW_NUMBER() OVER (ORDER BY [Datetime]) > 20 THEN SUM([Close]) OVER (ORDER BY [Datetime] ROWS BETWEEN 20 PRECEDING AND CURRENT ROW) END/21 as MA21 | |
,CASE WHEN ROW_NUMBER() OVER (ORDER BY [Datetime]) > 33 THEN SUM([Close]) OVER (OR |
NewerOlder