This file contains hidden or 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
plt.plot(df['tenkan_sen'], label='Tenkan sen', color='cornflowerblue', linewidth = 0.5) | |
plt.plot(df['kijun_sen'], label='Kijun sen', color='salmon', linewidth = 0.5) | |
plt.plot(df['senkou_span_a'], label='Senkou span A', color='lightgreen', linewidth = 0.5) | |
plt.plot(df['senkou_span_b'], label='Senkou span B', color='lightcoral', linewidth = 0.5) | |
plt.plot(df['chikou_span'], label='Chikou span', color='green', linewidth = 1) | |
plt.fill_between(df.index, df['senkou_span_a'], df['senkou_span_b'], where = df['senkou_span_a'] >= df['senkou_span_b'], color = 'honeydew') | |
plt.fill_between(df.index, df['senkou_span_a'], df['senkou_span_b'], where = df['senkou_span_a'] < df['senkou_span_b'], color = 'mistyrose') |
This file contains hidden or 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
import mplfinance as mpf | |
ichimoku_cloud = [ | |
mpf.make_addplot(df['tenkan_sen'], color = 'blue', width = 1), | |
mpf.make_addplot(df['kijun_sen'], color = 'red', width = 1), | |
mpf.make_addplot(df['senkou_span_a'], color = 'lightgreen', width = 0.5), | |
mpf.make_addplot(df['senkou_span_b'], color = 'lightcoral', width = 0.5), | |
mpf.make_addplot(df['chikou_span'], color = 'green', width = 1) | |
] |
This file contains hidden or 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
protected $moduleMapping = [ | |
"Mage_Sendfriend" => "Magento_SendFriend", | |
"Mage_AdminNotification" => "Magento_AdminNotification", | |
"Mage_Authorizenet" => "Magento_Authorizenet", | |
"Mage_Bundle" => "Magento_Bundle", | |
"Mage_Captcha" => "Magento_Captcha", | |
"Mage_Catalog" => "Magento_Catalog", | |
"Mage_CatalogInventory" => "Magento_CatalogInventory", | |
"Mage_CatalogRule" => "Magento_CatalogRule", | |
"Mage_CatalogSearch" => "Magento_CatalogSearch", |
This file contains hidden or 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
# use `amplify add <feature>` | |
$ amplify add analytics | |
$ amplify push |
This file contains hidden or 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
$ npm install aws-amplify | |
$ npm install aws-amplify-angular |
This file contains hidden or 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
# set endpoint variable | |
$export ApiGatewayEndpoint="$AppId.execute-api.us-east-1.amazonaws.com/v1" | |
# add a new user | |
curl -vvv -X POST -d '{"email": "[email protected]", "phone": "0123456789"}' -H "Content-Type: application/json" https://$ApiGatewayEndpoint/user | |
# list users | |
curl -vvv -X GET https://$ApiGatewayEndpoint/user |
This file contains hidden or 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
# import your swagger to apigateway | |
$ aws apigateway import-rest-api --fail-on-warnings --body file://swagger.json | |
# update cloudformation template | |
$ aws cloudformation update-stack --stack-name $your-stack-name --template-body file://template.json --capabilities CAPABILITY_IAM --parameters ParameterKey=S3Bucket,UsePreviousValue=true ParameterKey=S3Key,UsePreviousValue=true ParameterKey=ApiId,ParameterValue=$ApiId | |
# deploy to stage v1 | |
$ aws apigateway create-deployment --rest-api-id $ApiId --stage-name v1 |
This file contains hidden or 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
# replace all nine occurrences of $AWSRegion in swagger.json with the region that you are creating your API and Lamdba in | |
$ sed -i '.bak' 's/$AWSRegion/us-east-1/g' swagger.json | |
# get the LambdaArn | |
$ aws cloudformation describe-stacks --stack-name apigateway --query Stacks[0].Outputs | |
# replace all nine occurrences of $LambdaArn in swagger.json with the ARN from the stack output above (e.g. arn:aws:lambda:us-east-1:YYY:function:apigateway-Lambda-XXX) | |
$ LambdaArn/arn:aws:lambda:us-east-1:YYY:function:apigateway-Lambda-XXX/g' swagger.json |
This file contains hidden or 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
$ aws cloudformation create-stack --stack-name $your-stack-name --template-body file://template.json --capabilities CAPABILITY_IAM --parameters ParameterKey=S3Bucket,ParameterValue=$your-bucket-name | |
$ aws cloudformation describe-stacks --stack-name $your-stack-name --query Stacks[0].Outputs | |
$ aws cloudformation wait stack-create-complete |
This file contains hidden or 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
$ aws s3api create-bucket - bucket $your-bucket-name - region us-east-1 | |
$ aws s3 cp lambda.zip s3://$your-bucket-name/lambda.zip |
NewerOlder