Electrum bars can be made at a smelter by a dwarf with the furnace operating labor activated.
One gold bar and one silver bar, or one gold nugget and one silver ore (but not a mix of bars and ore), produces two electrum bars.
Smelting bars together consumes a value 30 material and a value 10 material to produce two units of value 20, thus producing no net gain (or loss); you're taking a high-value item and a medium-value item and averaging their values. Smelting the ore directly saves you two units of fuel (if you don't have access to magma). Moreover, low-value galena or tetrahedrite ore can be substituted for native silver or horn silver, producing more value overall than would be generated from smelting the ores separately. Thus, if you have access to a silver ore, it is always favourable value-wise to produce electrum bars over gold bars, unless your legendary metalsmith has a particular fancy for gold.