Focusing on problems such as complexities existing in compressed storage structures of the current data stream Top-k closed frequent itemsets algorithm and inaccuracy in the algorithm, the paper puts forward an algorithm of MTKCFI-SW by designing compact prefix pattern trees for compression and storage of effective information in data stream sliding windows. The CFP-tree, capable of promptly capturing newly added data stream information under circumstances of any sliding window sizes, does not need to fix the sizes of sliding windows and thus improves the flexibility of this algorithm. Research in dynamic determination of mining threshold and pruning threshold also helps to improve accuracy of this algorithm by adopting an effective approach in mining Top-k closed frequent itemsets in the environment of data stream. DOI: http://dx.doi.org/10.11591/telkomnika.v11i7.2825