Skip to content

Instantly share code, notes, and snippets.

View justislav's full-sized avatar

Justislav justislav

View GitHub Profile
@justislav
justislav / groupTree.gs
Created June 6, 2018 09:27
group & collapse top levels tree branches, remove all previous groups from current sheet
/** @OnlyCurrentDoc */
function getGroup(sheet, rowIndex) {
var groupDepth = sheet.getRowGroupDepth(rowIndex);
if (groupDepth) return sheet.getRowGroup(rowIndex, groupDepth)
else return null
}
function remove_all_groups() {
var spreadsheet = SpreadsheetApp.getActive();
import pandas
df = pandas.read_csv('stat.tsv',sep='\t')
df.dtypes
xf = df[df['status']=='passed']
len(df)
len(xf)
kf = df[df['status']!='passed']
kf.to_clipboard()
import arrow
xf = xf.sort(['login','ts'])