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
cimport cython | |
import numpy as np | |
cimport numpy as np | |
cdef extern from 'math.h': | |
float exp(float x) | |
float cos(float x) | |
float sin(float x) | |
float fabs(float x) |
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 psycopg2 as pg | |
import pandas.io.sql as psql | |
# get connected to the database | |
connection = pg.connect("dbname=mydatabase user=postgres") | |
dataframe = psql.frame_query("SELECT * FROM <tablename>", connection) |