As atomic operations, secure matrix-based computations using homomorphic encryption (HE) have attracted much attention in cloud-based machine learning. However, most existing secure matrix computation solutions that focus on HE schemes suffer efficiency loss as the size of the matrix, which greatly limits their applications in the big data environment. To address these issues, this paper proposes seIMC, an integer matrix computation scheme based on the Gentry-Sahai-Waters (GSW) scheme, to cope with privacy protection and secure computation of large-scale data. In detail, we translate the GSW scheme to encrypt an integer matrix modulo $q$ (i.e., a large positive integer), and homomorphically compute matrix addition and multiplication, which is a natural extension of HAO scheme. Besides, the correctness and security analysis of seIMC are shown, and complexity analysis is also given in this study. Furthermore, the proposed schemes are implemented, including public-key encryption and private-key encryption schemes. Compared with existing secure matrix computation schemes, the proposed scheme performs better in execution time. Finally, seIMC is applied to solve the problem of the number of ways in which any two participants make friends through $k$ steps in an encrypted social network. Experiments show that when the cloud server processes an integer matrix of 1000 people with a security level of 90, namely, 1 million data volumes, it only takes approximately 1.9 minutes for each homomorphic matrix multiplication. Hence, the practicality of the proposed seIMC in privacy protection under a big data environment is highly proven.