{ "cells": [ { "cell_type": "markdown", "id": "57688bf8-944c-4734-89b2-c97f17596fd0", "metadata": {}, "source": [ "# PubPart\n", "\n", "## Collaborations between Université Paris-Salcay and Stockholms Universitet\n", "\n", "Those plots present collaborations between the Université Paris-Saclay and Stockholms Universitet \n", "from 2020 to 2025 using data from OpenAlex.\n", "\n", "For the Université Paris-Salcay, we use the OpenAlex Institution ID I277688954 with its full ROR \n", "lineage (all the university's child structures).\n", "\n", "For Stockholms Universitet, we use the OpenAlex Institution ID I161593684 with its full ROR lineage\n", "(all the institution's child structures), the OpenAlex Publisher ID P4310320318 full lineage and the OpenAlex\n", "Funder ID F4320325669. This means that works which are either from author(s) from Stockholms Universitet, \n", "published by Stockholms Universitet or funded by Stockholms Universitet will be included in the analysis below.\n", "\n", "To run this notebook, you need at least 10 GB of RAM. You can reduce the year time frame for each plot if you \n", "want to reduce the memory requirements.\n", "\n", "Romain THOMAS 2025 \n", "DiBISO - Université Paris-Salcay" ] }, { "cell_type": "code", "execution_count": 1, "id": "1bfcdf22-91ca-4f2d-a255-d3835c8c49c2", "metadata": { "editable": true, "nbsphinx": "hidden", "slideshow": { "slide_type": "" }, "tags": [] }, "outputs": [], "source": [ "# This cell has the metadata: \"nbsphinx\": \"hidden\" to be hidden in the sphinx documentation\n", "\n", "# Create figure directory\n", "\n", "import os\n", "\n", "os.makedirs(\"figures/pubpart\", exist_ok=True)" ] }, { "cell_type": "markdown", "id": "b7f5ab0d-1c7d-4dc2-a7a6-c85ef7640adb", "metadata": {}, "source": [ "## OpenAlex Topics in works in collaboration" ] }, { "cell_type": "code", "execution_count": 2, "id": "d85e0e46-a4f1-4925-99eb-434d14756755", "metadata": { "editable": true, "slideshow": { "slide_type": "" }, "tags": [] }, "outputs": [], "source": [ "from dibisoplot.pubpart import TopicsCollaborations\n", "\n", "tc = TopicsCollaborations(\n", " \"I277688954\",\n", " year=\"2020-2025\",\n", " language=\"en\",\n", " entity_openalex_filter_field = \"authorships.institutions.lineage\",\n", " secondary_entity_id = [\"I161593684\", \"P4310320318\", \"F4320325669\"],\n", " secondary_entity_filter_field = [\n", " \"authorships.institutions.lineage\",\n", " \"locations.source.publisher_lineage\",\n", " \"grants.funder\"\n", " ]\n", ")\n", "\n", "tc_fig = tc.get_figure()" ] }, { "cell_type": "code", "execution_count": 3, "id": "85f2c001-3aa4-4dd5-8236-391da65df27b", "metadata": { "editable": true, "nbsphinx": "hidden", "slideshow": { "slide_type": "" }, "tags": [] }, "outputs": [], "source": [ "# This cell has the metadata: \"nbsphinx\": \"hidden\" to be hidden in the sphinx documentation\n", "\n", "tc_fig.update_layout(\n", " autosize=True,\n", " width=None, # Let the iframe control width\n", " height=None, # Let the iframe control height\n", ")\n", "tc_fig.write_html(\n", " \"figures/pubpart/tc_fig.html\",\n", " include_plotlyjs=\"cdn\",\n", " full_html=False,\n", " config={\"responsive\": True}\n", ")" ] }, { "cell_type": "markdown", "id": "fe67a6f4-fcf7-48b4-b35c-704a201cf6d9", "metadata": {}, "source": [ "