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
import pandas as pd | |
import numpy as np | |
def create_shift(df, column, shift_value, method, name): | |
""" | |
Create a new column based on an existing column with a given shift value. The shifted column is indexed based on an | |
existing index with he missing values interpolated using the given method. | |
:param df: DataFrame to create the shift in. |
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
import os | |
import configparser as cp | |
import shutil | |
import pysftp | |
import paramiko | |
from paramiko.py3compat import decodebytes | |
# credentials file name | |
CREDENTIALS_FILE = 'sftp_sync_credentials.properties' |
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
class Node: | |
def __init__(self, value): | |
self.value = value | |
self.next_node = None | |
def get_value(self): | |
return self.value | |
def get_next_node(self): | |
return self.next_node |