docs: def network_expansion_diff (networkA, networkB, filename=None, boundaries=[]):
      """Plot relative network expansion derivation of AC- and DC-lines.
      
      Parameters
      ----------
      networkA: PyPSA network container
          Holds topology of grid including results from powerflow analysis
      networkB: PyPSA network container
          Holds topology of grid including results from powerflow analysis
      filename: str or None
          Save figure in this direction
      boundaries: array
         Set boundaries of heatmap axis
      
      """
  
      cmap = plt.cm.jet
      
      array_line = [['Line'] * len(networkA.lines), networkA.lines.index]
  
      extension_lines = pd.Series(100 *\
                                   ((networkA.lines.s_nom_opt - \
                                      networkB.lines.s_nom_opt)/\
                                      networkA.lines.s_nom_opt  ).values,\
                                  index=array_line)
  
      array_link = [['Link'] * len(networkA.links), networkA.links.index]
  
      extension_links = pd.Series(100 *
                                   ((networkA.links.p_nom_opt -\
                                      networkB.links.p_nom_opt)/\
                                      networkA.links.p_nom_opt).values,\
                                  index=array_link)
  
      extension = extension_lines.append(extension_links)
  
      ll = networkA.plot(
          line_colors=extension,
          line_cmap=cmap,
          bus_sizes=0,
          title="Derivation of AC- and DC-line extension",
          line_widths=2)
  
      if not boundaries:
          v = np.linspace(min(extension), max(extension), 101)
          boundaries = [min(extension).round(0), max(extension).round(0)]
          
      else:
          v = np.linspace(boundaries[0], boundaries[1], 101)
          
      if not extension_links.empty:
          cb_Link = plt.colorbar(ll[2], boundaries=v,
                        ticks=v[0:101:10])
          cb_Link.set_clim(vmin=boundaries[0], vmax=boundaries[1])
          
          cb_Link.remove()
          
      cb = plt.colorbar(ll[1], boundaries=v,
                        ticks=v[0:101:10], fraction=0.046, pad=0.04)
      
      cb.set_clim(vmin=boundaries[0], vmax=boundaries[1])
      cb.set_label('line extension derivation  in %')
  
      if filename is None:
          plt.show()
      else:
          plt.savefig(filename)
          plt.close()