code: def latexfig():
      pio.templates.default = None
      trace1 = go.Scatter(x=[1, 2, 3, 4], y=[1, 4, 9, 16])
      trace2 = go.Scatter(x=[1, 2, 3, 4], y=[0.5, 2, 4.5, 8])
      data = [trace1, trace2]
      layout = go.Layout(
          xaxis=dict(
              title="$\\sqrt{(n_\\text{c}(t|{T_\\text{early}}))}$",
              showticklabels=False,
          ),
          yaxis=dict(
              title="$d, r \\text{ (solar radius)}$",
              showticklabels=False,
          ),
          showlegend=False,
          font={"family": "Arial", "size": 12},
      )
      fig = go.Figure(data=data, layout=layout)
      yield fig
      pio.templates.default = "plotly"
  
imports: import plotly
  import plotly.io
  import plotly.graph_objs
  import os
  import shutil
  import pytest
  import sys
  import pandas
  from io import BytesIO
label_desc: Use image node_id 5 for calling a global function with example usage: latexfig() without return types