Commit 8a7ba810 authored by Giorgio Calderone's avatar Giorgio Calderone
Browse files

Updated

parent a44bac5f
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -35,9 +35,10 @@ function multi_fit(source::QSO{TRecipe}; ref_id=1) where TRecipe <: q1927p654
            model[:galaxy] = QSFit.hostgalaxy(source.options[:host_template])
            model[:Continuum] = SumReducer([:qso_cont, :galaxy])

            #Allow half of the flux to the continuum and half to host galaxy
            model[:galaxy].norm.val = Spline1D(λ, source.data[id].val, k=1, bc="error")(5500.) / 2.
            model[:qso_cont].x0.val /= 2
            # Split total flux between continuum and host galaxy
            vv = Spline1D(λ, source.data[id].val, k=1, bc="error")(5500.)
            model[:galaxy].norm.val  = 1/3 * vv
            model[:qso_cont].x0.val *= 2/3 * vv / Spline1D(λ, model(:qso_cont), k=1, bc="error")(5500.)

            if id != ref_id
                model[:galaxy].norm.fixed = true
+4 −3
Original line number Diff line number Diff line
@@ -24,9 +24,10 @@ function fit(source::QSO{TRecipe}; id=1) where TRecipe <: q1927p654
        model[:galaxy] = QSFit.hostgalaxy(source.options[:host_template])
        model[:Continuum] = SumReducer([:qso_cont, :galaxy])

        #Allow half of the flux to the continuum and half to host galaxy
        model[:galaxy].norm.val = Spline1D(λ, source.data[id].val, k=1, bc="error")(5500.) / 2.
        model[:qso_cont].x0.val /= 2
        # Split total flux between continuum and host galaxy
        vv = Spline1D(λ, source.data[id].val, k=1, bc="error")(5500.)
        model[:galaxy].norm.val  = 1/3 * vv
        model[:qso_cont].x0.val *= 2/3 * vv / Spline1D(λ, model(:qso_cont), k=1, bc="error")(5500.)
    end

    # Balmer continuum and pseudo-continuum