I had the same problem a couple of days ago. And today I fixed. I had Apex legends installed on my pc but never played it before. A couple of days ago I decided that I wanted to try it, but whenever I tried it, i was getting prediction error and packet loss symbols all the time. The game was literally unplayable. So here is how I fixed my problem and hopefully that will work someone else as well.
All you need to do is forward the network ports that Apex legendes needs. Once I did that, the problem was solved.
My computer is connected via LAN cable to D-LINK router I have. And the router is connected to a CISCO cable modem modem via LAN cable. So if you have kind of the same the setup you would to do port forwarding on both devices (router and cable modem).
Here is the link of the port that you need to do port forwarding for Apex Legends
https://help.ea.com/en-au/help/faq/opening-tcp-or-udp-ports-for-connection-issues/?product=apex-legends&ajax=1
Here is a link on how to port forwarding:
https://www.youtube.com/watch?v=NTLDsEuQlYc
But keep mind that every cable modem and router settings a slightly different.