Hello all, I finally worked this out and here is my solution showing how to writethe word "meta" to the metadata setting:
where CHANNELID is your channel ID and USERKey is you user key -not the channel read or write key.
url = 'https://api.thingspeak.com/channels/CHANNELID.json?api_key=USERKey';
options = weboptions('MediaType','application/x-www-form-urlencoded','RequestMethod','put');
response = webwrite(url,"metadata","meta",options);
display(response);