Skip to content

Instantly share code, notes, and snippets.

View martisak's full-sized avatar

Martin Isaksson martisak

View GitHub Profile
@martisak
martisak / cognitive.md
Last active February 17, 2026 09:08
Some prompts I use to improve my academic writing

Cognitive-Friction Review Prompt

Role

You are not a co-author, editor, or assistant. You are an adversarial cognitive auditor whose job is to surface flaws, blind spots, and weak reasoning in the document below. Politeness is not a goal. Accuracy and pressure-testing are.

Constraints

Assume the author (me) is intelligent, experienced, and still wrong in important ways.

@martisak
martisak / seattle_table.py
Created October 3, 2021 15:04
Sparklines table generation
import pandas as pd
import os
import numpy as np
def sparkline(data, endpoints=False, ci=True):
d = data.Mean_TemperatureC.values
r = [-12, 31]
@martisak
martisak / macros.tex
Last active October 3, 2021 15:00
Macros for Sparkline post
\usepackage{booktabs}
\usepackage{sparklines}
\usepackage[labelfont=bf]{caption}
\usepackage{fontspec}
\setmainfont{Myriad Pro}
\usepackage{multirow}
%dashed line
\documentclass[varwidth=\maxdimen]{standalone}
\input{includes/macros}
\begin{document}
\begin{table}
\centering
\noindent\begin{minipage}{10cm}
\caption{Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua.}
\end{minipage}
import pandas as pd
try:
from BeautifulSoup import BeautifulSoup
except ImportError:
from bs4 import BeautifulSoup
import requests
from pathlib import Path
import os
@martisak
martisak / gist:4b784f54c8e6df06a1e88c63cb5157c1
Last active February 24, 2021 17:01
WASP Acknowledgment
This work was partially supported by the Wallenberg AI, Autonomous Systems and Software Program (WASP) funded by the Knut and Alice Wallenberg Foundation.
@martisak
martisak / main.py
Last active August 31, 2017 22:12
Colored logs in Python
from util import logger
if __name__ == "__main__":
logger.info("Main just started")
@martisak
martisak / subfig.tex
Created July 6, 2017 17:55 — forked from RodrigoPrior/subfig.tex
subfig latex example
\documentclass[11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage{graphicx}
\usepackage{subfig}
\begin{document}
\begin{figure}[!ht]
\centering
\caption{Caption superior.}

Keybase proof

I hereby claim:

  • I am martisak on github.
  • I am martisak (https://keybase.io/martisak) on keybase.
  • I have a public key whose fingerprint is D177 6FBA F943 270B 8D0B 25A4 319A 8541 83E5 FD61

To claim this, I am signing this object: