Merge "Make Ubuntu installation even more fail safe"
diff --git a/KorAPClient/__init__.py b/KorAPClient/__init__.py
index c6e6699..1e0ba2c 100644
--- a/KorAPClient/__init__.py
+++ b/KorAPClient/__init__.py
@@ -105,7 +105,7 @@
Returns:
DataFrame with columns `'node', 'collocate', 'label', 'vc','webUIRequestUrl', 'w', 'leftContextSize',
- 'rightContextSize', 'N', 'O', 'O2', 'E', 'pmi', 'mi2', 'mi3', 'logDice' `
+ 'rightContextSize', 'N', 'O', 'O1', 'O2', 'E', 'pmi', 'mi2', 'mi3', 'logDice', 'll'`
Example:
```
diff --git a/Readme.md b/Readme.md
index d83772c..da2981a 100644
--- a/Readme.md
+++ b/Readme.md
@@ -65,13 +65,16 @@
kcon = KorAPConnection(verbose=True)
-vcs = ["textType=/Zeit.*/ & pubPlaceKey=" + c + " & pubDate in " + str(y) for c in COUNTRIES for y in YEARS]
+vcs = [f"textType=/Zeit.*/ & pubPlaceKey={c} & pubDate in {y}" for c in COUNTRIES for y in YEARS]
df = KorAPClient.ipm(kcon.frequencyQuery(QUERY, vcs))
+
df['Year'] = [y for c in COUNTRIES for y in YEARS]
df['Country'] = [c for c in COUNTRIES for y in YEARS]
+df['error_y'] = df["conf.high"] - df["ipm"]
+df['error_y_minus'] = df["ipm"] - df["conf.low"]
fig = px.line(df, title=QUERY, x="Year", y="ipm", color="Country",
- error_y="conf.high", error_y_minus="conf.low")
+ error_y="error_y", error_y_minus="error_y_minus")
fig.show()
```
![Frequency per million words of “Hello World“ in DE vs. AT from 2010 to 2018 in newspapers and magazines](figures/hello-world.png)
diff --git a/examples/hello_world.py b/examples/hello_world.py
index 6ac91cc..f660a6d 100755
--- a/examples/hello_world.py
+++ b/examples/hello_world.py
@@ -8,13 +8,15 @@
kcon = KorAPConnection(verbose=True)
-vcs = ["textType=/Zeit.*/ & pubPlaceKey=" + c + " & pubDate in " + str(y) for c in COUNTRIES for y in YEARS]
+vcs = [f"textType=/Zeit.*/ & pubPlaceKey={c} & pubDate in {y}" for c in COUNTRIES for y in YEARS]
df = KorAPClient.ipm(kcon.frequencyQuery(QUERY, vcs))
print(df)
df['Year'] = [y for c in COUNTRIES for y in YEARS]
df['Country'] = [c for c in COUNTRIES for y in YEARS]
+df['error_y'] = df["conf.high"] - df["ipm"]
+df['error_y_minus'] = df["ipm"] - df["conf.low"]
fig = px.line(df, title=QUERY, x="Year", y="ipm", color="Country",
- error_y="conf.high", error_y_minus="conf.low")
+ error_y="error_y", error_y_minus="error_y_minus")
fig.show()
diff --git a/figures/hello-world.png b/figures/hello-world.png
index 6e2f27d..58579df 100644
--- a/figures/hello-world.png
+++ b/figures/hello-world.png
Binary files differ