diff --git a/notebooks/LPD/LPDChar_Darks_NBC.ipynb b/notebooks/LPD/LPDChar_Darks_NBC.ipynb
index 5bec878b3381961f1bf9502bab6efd8173cd921b..095a747d79d835a84e091cb7a5652b89a482a4a9 100644
--- a/notebooks/LPD/LPDChar_Darks_NBC.ipynb
+++ b/notebooks/LPD/LPDChar_Darks_NBC.ipynb
@@ -1190,7 +1190,8 @@
     "            table.append(line)\n",
     "\n",
     "display(Markdown('### Number of bad pixels ###'.format(qm)))\n",
-    "md = display(Latex(tabulate.tabulate(table, tablefmt='latex', \n",
+    "if len(table)>0:\n",
+    "    md = display(Latex(tabulate.tabulate(table, tablefmt='latex', \n",
     "                                     headers=[\"Pixel type\", \"Threshold\", \"New constant\", \"Old constant \"])))  "
    ]
   },