This should have nothing to do with awk, but all with gnuplots expectation for plot and load commands.
In my understanding reading gnuplot help output and trying the samples you provided:
plot "<awk '{print $1,$2}' data.txt"
is just a complicated way, to offer via popen call available on your system a file like object, the plot command then reads from the x, y points.
You second script does something different, as the load command now receives in a first line a command it cannot satisfy (namely plot followed by an x and an y value) and subsequent commands would be received even without any prefix command (next line simply 2 2
in this case.
In my memory of active gnuplot usage - years ago if not decades ;-) - load is like well load, where you can compose plotting code from modules, but these must contain valid gnuplot commands.
The help for load on my system gives:
gnuplot> help load
The `load` command executes each line of the specified input file as if it
had been typed in interactively. Files created by the `save` command can
later be `load`ed. Any text file containing valid commands can be created
and then executed by the `load` command. Files being `load`ed may themselves
contain `load` or `call` commands. See `comments` for information about
comments in commands. To `load` with arguments, see `call`.
Syntax:
load "<input-file>"
The name of the input file must be enclosed in quotes.
The special filename "-" may be used to `load` commands from standard input.
This allows a `gnuplot` command file to accept some commands from standard
input. Please see help for `batch/interactive` for more details.
On some systems which support a popen function (Unix), the load file can be
read from a pipe by starting the file name with a '<'.
Examples:
load 'work.gnu'
load "func.dat"
load "< loadfile_generator.sh"
The `load` command is performed implicitly on any file names given as
arguments to `gnuplot`. These are loaded in the order specified, and
then `gnuplot` exits.
I always solved generating matching files and have some call magic for the gnuplot calls to parametrize the plots.