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
from xlrd import open_workbook | |
import numpy as np | |
import statsmodels.api as sm | |
''' | |
HOW TO RUN | |
Make sure FILE_NAME matches the name of the spreadsheet (change any spaces to underscores). | |
Make sure DEPEDENT_VAR_COL_NUMBER is set to the number of the column where your depedent variable is. |
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
127.0.0.1 api.ak.facebook.com | |
127.0.0.1 api.connect.facebook.com | |
127.0.0.1 api.facebook.com | |
127.0.0.1 app.facebook.com | |
127.0.0.1 apps.facebook.com | |
127.0.0.1 ar-ar.facebook.com | |
127.0.0.1 badge.facebook.com | |
127.0.0.1 blog.facebook.com | |
127.0.0.1 connect.facebook.com | |
127.0.0.1 connect.facebook.net |
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 requests | |
from selenium import webdriver | |
from selenium.webdriver.common.by import By | |
from selenium.webdriver.support.ui import WebDriverWait | |
from selenium.webdriver.support import expected_conditions as EC | |
from bs4 import BeautifulSoup | |
driver = webdriver.Firefox(executable_path='C:\\Users\\steal\\workplace\\scrape\\geckodriver.exe') | |
for i in range(1, 24): |
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
convert -density 150 input.pdf -colorspace gray -linear-stretch 3.5%x10% -blur 0x0.5 -attenuate 0.25 +noise Gaussian -rotate 0.5 temp.pdf | |
gs -dSAFER -dBATCH -dNOPAUSE -dNOCACHE -sDEVICE=pdfwrite -sColorConversionStrategy=LeaveColorUnchanged dAutoFilterColorImages=true -dAutoFilterGrayImages=true -dDownsampleMonoImages=true -dDownsampleGrayImages=true -dDownsampleColorImages=true -sOutputFile=output.pdf temp.pdf |
OlderNewer