This study investigates an unmanned aerial vehicle (UAV)-assisted non-orthogonal multiple access (NOMA) based on mobile edge computing (MEC) in Internet of Things (IoT) networks. Specifically, we consider two IoT device (ID) clusters with resource limits and a UAV with an MEC server operating as a wireless power transfer (WPT) station. We present a protocol termed time switching (TS)-UAV NOMA MEC energy harvesting (EH) (TS-UNME), which includes four phases: energy harvesting, task-offloading, task-computing, and task-downloading. For system performance evaluation, we propose a closed-form expression of successful computation probability (SCP) that accounts for imperfect channel state information (ICSI) across the Rayleigh fading channel. In addition, we present a system performance optimization problem, which optimizes SCP by establishing time switching ratio (TSR) and height of UAV. A particle swarm optimization (PSO)-based approach is utilized for solving the problem. Finally, Monte Carlo simulations confirm our analysis's precision.